1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

How to run php script?

Discussion in 'Site & Server Administration' started by samlocalguy, Jul 17, 2006.

  1. #1
    Hello Friends:)

    I loves web-designing. I make 100's of website using HTML, DHTML, Javescript.

    I havn't knowledge of backend. How to create and setup?

    I got a Joke Script from my friend.

    I want to run php Joke script in my website.

    The hosting which I using accept PHP sites.

    I paste joke script in my ftp://www.mydomain.com
    But i am unable to run that script?
    I also tried some other script but still failed.

    So, please tell me step by step how I can run my PHP script?
    I am totally new to PHP

    Sam
     
    samlocalguy, Jul 17, 2006 IP
  2. T0PS3O

    T0PS3O Feel Good PLC

    Messages:
    13,219
    Likes Received:
    777
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Ask your host whether you have Apache and PHP actually running.
     
    T0PS3O, Jul 17, 2006 IP
  3. Avatar

    Avatar Peon

    Messages:
    79
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Realy easy,lol just save the file as .php and if the host allows PHP it will work.
     
    Avatar, Jul 17, 2006 IP
  4. Andy-V

    Andy-V Active Member

    Messages:
    409
    Likes Received:
    64
    Best Answers:
    0
    Trophy Points:
    90
    #4
    When you visit your site, what comes up? An error code? Nothing?
     
    Andy-V, Jul 17, 2006 IP
  5. samlocalguy

    samlocalguy Active Member

    Messages:
    1,297
    Likes Received:
    34
    Best Answers:
    0
    Trophy Points:
    90
    #5
    When I tried to open www.mydomain.com/jokepage.php . It asks for downloading page? when i click save or open
    it opens blank Notepad page?
     
    samlocalguy, Jul 17, 2006 IP
  6. giraph

    giraph Guest

    Messages:
    484
    Likes Received:
    27
    Best Answers:
    0
    Trophy Points:
    0
    #6
    Your host does not support PHP.
     
    giraph, Jul 17, 2006 IP
  7. sandossu

    sandossu Guest

    Messages:
    2,274
    Likes Received:
    88
    Best Answers:
    0
    Trophy Points:
    0
    #7
    you save pages as .php and use them on an apache server with php
     
    sandossu, Jul 17, 2006 IP
  8. ahref

    ahref Well-Known Member

    Messages:
    1,123
    Likes Received:
    67
    Best Answers:
    0
    Trophy Points:
    170
    #8
    I think php is not enabled in your account
     
    ahref, Jul 18, 2006 IP
  9. samlocalguy

    samlocalguy Active Member

    Messages:
    1,297
    Likes Received:
    34
    Best Answers:
    0
    Trophy Points:
    90
    #9
    Grunt

    I think you are right. But with same hosting my friends are runnig php script.
    First I run asp script on it. asp works fine. But php not.
    I am trying to run php script on my hosting where ASP already used. Is it the reason php not working. I have to delete my asp setting first???? Is it necessary.

    Can anyone tell me any site which provide free php hosting where i can test my php script??
     
    samlocalguy, Jul 18, 2006 IP
  10. T0PS3O

    T0PS3O Feel Good PLC

    Messages:
    13,219
    Likes Received:
    777
    Best Answers:
    0
    Trophy Points:
    0
    #10
    Listen, there's not much we can do because we don't know your hosting facilities, hence all of us recommending you ask your host. So.... Ask your host.

    Try hostmatrix for free PHP hosting.

    http://www.hostmatrix.org/
     
    T0PS3O, Jul 18, 2006 IP
  11. DrMalloc

    DrMalloc Peon

    Messages:
    130
    Likes Received:
    9
    Best Answers:
    0
    Trophy Points:
    0
    #11
    http://www.apachefriends.org/en/xampp.html

    That will let you install PHP, MySQL and Apache on your own machine easily for testing scripts and learning, and it's all free.
     
    DrMalloc, Jul 18, 2006 IP
  12. 4forumsID

    4forumsID Peon

    Messages:
    162
    Likes Received:
    13
    Best Answers:
    0
    Trophy Points:
    0
    #12
    try putting this in a file

    <?
    phpinfo();
    ?>

    and then check that file to see if you have php installed ... www.domain.com/phpfile.php
     
    4forumsID, Jul 18, 2006 IP
  13. samlocalguy

    samlocalguy Active Member

    Messages:
    1,297
    Likes Received:
    34
    Best Answers:
    0
    Trophy Points:
    90
    #13
    Thanx to all,

    I paste my joke script for demo on free space http://myjokes.110mb.com/
    But its is displaying error. Check and tell me where I am worng. I tried to submit Joke in addjoke.php but its ask for downloanding??

    Am I need to install anything else? SQL, Appache etc.?
     
    samlocalguy, Jul 20, 2006 IP
  14. DrMalloc

    DrMalloc Peon

    Messages:
    130
    Likes Received:
    9
    Best Answers:
    0
    Trophy Points:
    0
    #14
    It looks like the MySQL db details haven't been set properly, so it is unable to connect to the database.
     
    DrMalloc, Jul 20, 2006 IP
  15. phog

    phog Peon

    Messages:
    10
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #15
    i think you should ask your host everyone is right, php just should run if you are capable of hosting it...
     
    phog, Jul 20, 2006 IP
  16. samlocalguy

    samlocalguy Active Member

    Messages:
    1,297
    Likes Received:
    34
    Best Answers:
    0
    Trophy Points:
    90
    #16
    But it is free hosting. can they set my site setting.

     
    samlocalguy, Jul 20, 2006 IP
  17. iowadawg

    iowadawg Prominent Member

    Messages:
    10,918
    Likes Received:
    811
    Best Answers:
    0
    Trophy Points:
    380
    #17
    That you are not uploading your script right and following the installation guide for the script.
    If you do not have an installation guide, you got screwed if you do not know what to do.
    Permissions have to be set on some files, mysql has to be set up, then the database uploading correctly, etc etc etc

    Actually, more information from you is needed to even begin understanding what your problem really is.
     
    iowadawg, Jul 20, 2006 IP
  18. coderlinks

    coderlinks Peon

    Messages:
    282
    Likes Received:
    19
    Best Answers:
    0
    Trophy Points:
    0
    #18
    coderlinks, Jul 21, 2006 IP
  19. sandossu

    sandossu Guest

    Messages:
    2,274
    Likes Received:
    88
    Best Answers:
    0
    Trophy Points:
    0
    #19
    sandossu, Jul 21, 2006 IP
  20. samlocalguy

    samlocalguy Active Member

    Messages:
    1,297
    Likes Received:
    34
    Best Answers:
    0
    Trophy Points:
    90
    #20
    You are right. It is impossible to setup any script without proper knowledge. so, I start learning PHP. I think this is the only way to run my script.
     
    samlocalguy, Jul 26, 2006 IP