Hi I was wondering if you guys could help me with a few problems I am having getting some php code to render. I don't know all that much about php I am sort of a copy and paste kind of guy. Maybe I am a complete idiot and this stuff would work if I knew anything.
I have two seperate problems.
1) I have a site that uses header.php and footer.php files so that I can update one file instead of many. I was also using the code I found at
this site so that the title tag could be different on each page.
Here is an example of the code for the index
[php]<? $strTitle = 'Michèle’s agenda';$strCaption = 'Agenda';include("http://michelelosier.com/php/header.php");?>[/php]
I developed the site on my mac and everything worked fine I also uploaded to one server (a subdomain) running php 4.2 and everything was fine. I then uploaded it to the real domain on a different server with php 4.12 and it didn't show up at all. Is the new servre missing a possible module or something like that? Is there anyway I can get the stuff to work or should I look for a different server? Do I or can I define the function somehow?
2) I was using a script I found
here so that I could rotate an between two images everytime a certain page reloaded. Once again this worked fine on my mac and on the subdomain but when I put it on the other server I get this error:
Fatal error: Call to undefined function: showad() in /directory/blah/blal/index.php on line 8
I wrote to there support center and this was their response:
Honestly, I'm not sure how I can help here. As you can see, even PHP's main site does not list the showad() function:
http://www.php.net/quickref.php
Please let us know if there's anything we can do...
I then asked about there version of php and this was the response;
I doubt that it has anything to do with the version of PHP as 4.12 is not very old itself. Maybe your previous host had compileed PHP with some modules that we ddn't? We obviously will update PHP in the future, but there's no set date as of right now.
Now in my opinion these are not very insightful or useful responses. Does anybody have any ideas how to fix this or do any of you have a quick bit of code that would rotate two images that don't need to link to anything. Is there some way I can define the function so that it works? I did the correct include( ) thingy in the header as well
Any help on this would be greatly appreciated.
One more problem I forgot to mention. I made a gallery of pictures and I each gallery page has something like this at the top
[php]<? $strTitle = 'page title';$strCaption = 'title of picture';$strCaption2 = 'dexcription of picture'; $strPrev = 'cosi_02.php';include("http://michelelosier.com/php/photo_head_v_eng.php");?>
<img src="http://michelelosier.com/images/photos/cosi_03.jpg" alt="" width="425" height="640" hspace="0" border="0">[/php]
the $strPrev and $strNext are for images in the header that will lead to either the previous page or the next one in the gallery. Once again it worked on the mac, the subdomain but not the other one. Help