How can i add php code to my post in blogspot?

Discussion in 'Blogging' started by comboy, Sep 23, 2007.

  1. #1
    How can i add php code to my post in blogspot? I have some PHP code and want to post them into my blog. But blogspot remove all tags. How can i add php code to my post.
    Thanks
     
    comboy, Sep 23, 2007 IP
  2. appleiphone

    appleiphone Active Member

    Messages:
    546
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    80
    #2
    t think cant add php code into blogspot.
    Only html
     
    appleiphone, Sep 23, 2007 IP
  3. sat123

    sat123 Banned

    Messages:
    1,600
    Likes Received:
    45
    Best Answers:
    0
    Trophy Points:
    0
    #3
    no php only html and javascript (not sure as i was using blogger a year ago)
     
    sat123, Sep 23, 2007 IP
  4. nks

    nks Well-Known Member

    Messages:
    1,602
    Likes Received:
    40
    Best Answers:
    0
    Trophy Points:
    160
    #4
    Most probably, you can't do that.
    But, are you able to have IFRAME? If so, then you can link that to an external source, where you do your PHP code.
     
    nks, Sep 23, 2007 IP
  5. ruchirkc

    ruchirkc Peon

    Messages:
    86
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    0
    #5
    I don't think that it's possible...
     
    ruchirkc, Sep 23, 2007 IP
  6. comboy

    comboy Well-Known Member

    Messages:
    328
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    103
    #6
    We misunderstand. I want to post those code to my post. But i really dont know how to do.
    Example:
    
    <html>
     <head>
      <title>PHP Test</title>
     </head>
     <body>
     <?php echo '<p>Hello World</p>'; ?>
     </body>
    </html>
    
    Code (markup):
    But when i write this code, Blogspot remove all except: Hello world. :(
     
    comboy, Sep 23, 2007 IP
  7. comboy

    comboy Well-Known Member

    Messages:
    328
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    103
    #7
    Thanks. I have find the way to do this.
     
    comboy, Sep 23, 2007 IP
  8. ramzwatcher

    ramzwatcher Peon

    Messages:
    67
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #8
    can you share how u did it?

    as far as i know, blogger don't support php in their programming language.

    thanks
     
    ramzwatcher, Sep 24, 2007 IP
  9. ColorWP.com

    ColorWP.com Notable Member

    Messages:
    3,121
    Likes Received:
    100
    Best Answers:
    1
    Trophy Points:
    270
    #9
    You can't use PHP as programing language in blogspot. It has it's own programing language, but I think you wanted to quote a code in your blog post (for example to post a PHP tutorial). In this case you have to escape it and then place it in "edit HTML" mode. It should do the trick.
     
    ColorWP.com, Sep 24, 2007 IP
  10. comboy

    comboy Well-Known Member

    Messages:
    328
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    103
    #10
    Yes, you are rite.
     
    comboy, Sep 24, 2007 IP
  11. ramzwatcher

    ramzwatcher Peon

    Messages:
    67
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #11
    thanks dude for the answer. I just know about that site, thanks to you :D
     
    ramzwatcher, Sep 24, 2007 IP