Go Back   CodingForums.com > :: Server side development > PHP

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 08-07-2012, 11:19 AM   PM User | #1
countrydj
Regular Coder

 
Join Date: Nov 2011
Location: Preston, UK
Posts: 130
Thanks: 36
Thanked 0 Times in 0 Posts
countrydj is an unknown quantity at this point
PHP won't work with Firefox

Hi Guys...

I have a web site that uses a little PHP.
This is the bit that doesn't work.
PHP Code:
<?php
$hmenu
=join('',file('files/hmenu.txt'));
?>


<?php echo $hmenu ?>
This is where the display code is:
Code:
<tr valign="bottom">
	<td>
	    <? echo $hmenu ?> 
	</td>
</tr>
I'm convinced that it is because <? echo $hmenu ?> is within a table.

I have another php link. NOT inside a table, and that works OK.

This is not a problem with IE.

Can anybody advise me ??

Thanks,
__________________
The MAN, The MYTH, The LEGEND:
John C
________________________________
Support your local Country Music Club
countrydj is offline   Reply With Quote
Old 08-07-2012, 11:51 AM   PM User | #2
AndrewGSW
Senior Coder

 
Join Date: Apr 2011
Location: London, England
Posts: 2,120
Thanks: 15
Thanked 354 Times in 353 Posts
AndrewGSW will become famous soon enough
PHP Code:
<?php echo $hmenu ?>
__________________
"I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.
Validate your HTML and CSS
AndrewGSW is offline   Reply With Quote
Users who have thanked AndrewGSW for this post:
countrydj (08-07-2012)
Old 08-07-2012, 02:40 PM   PM User | #3
countrydj
Regular Coder

 
Join Date: Nov 2011
Location: Preston, UK
Posts: 130
Thanks: 36
Thanked 0 Times in 0 Posts
countrydj is an unknown quantity at this point
Hi AndrewGSW
Many thanks for your reply.

After I posted my problem I changed to your suggested code and it didn't work.

Cheers,
__________________
The MAN, The MYTH, The LEGEND:
John C
________________________________
Support your local Country Music Club

Last edited by countrydj; 08-07-2012 at 02:57 PM..
countrydj is offline   Reply With Quote
Old 08-07-2012, 03:03 PM   PM User | #4
tangoforce
Senior Coder

 
tangoforce's Avatar
 
Join Date: Feb 2011
Location: Your Monitor
Posts: 3,502
Thanks: 45
Thanked 439 Times in 428 Posts
tangoforce will become famous soon enoughtangoforce will become famous soon enough
Quote:
Originally Posted by countrydj View Post
After I posted my problem I changed to your suggested code and it didn't work.
That depends on what you mean by "didn't work".

IF you're still seeing <? echo $hmenu ?> in your html then you've not changed the correct part of your php code.

If you're referring to something else that "didn't work" then you need to tell us more about it

PHP short tags <? are not enabled on every server (for good reason - .xml files also use <? in them) so you must be prepared to use <?php in all of your php code instead.
__________________
Please wrap your code in [php] tags. It is a sticky topic and it HELPS us to HELP YOU!
TIP: Coding styles and $end errors :::::::::: TIP: Warning: Cannot modify header information - headers already sent :::::::::: TIP: Quotes / Parse error: syntax error, unexpected T_..
PHP Code:
//Please don't use this for your form processing:
if (isset($_POST['submit']))
//Internet explorer has a bug and does not always send the submit value. 
Explanation: The IE if(isset($_POST['submit'])) bug explained.
tangoforce is online now   Reply With Quote
Old 08-07-2012, 03:13 PM   PM User | #5
countrydj
Regular Coder

 
Join Date: Nov 2011
Location: Preston, UK
Posts: 130
Thanks: 36
Thanked 0 Times in 0 Posts
countrydj is an unknown quantity at this point
Hi tangoforce

Sorry I didn't make myself clearer.

I changed the tag to <?php echo $hmenu ?> just after I made my first post.

I normally use IE, but by showing somebody the site, which is:

http://swarbrick-racing.co.uk

in Firefox I foud that the top menu didn't work, but the bottom menu, which is NOT inside a table, did work.
__________________
The MAN, The MYTH, The LEGEND:
John C
________________________________
Support your local Country Music Club
countrydj is offline   Reply With Quote
Old 08-07-2012, 03:29 PM   PM User | #6
tangoforce
Senior Coder

 
tangoforce's Avatar
 
Join Date: Feb 2011
Location: Your Monitor
Posts: 3,502
Thanks: 45
Thanked 439 Times in 428 Posts
tangoforce will become famous soon enoughtangoforce will become famous soon enough
Quote:
Originally Posted by countrydj View Post
in Firefox I foud that the top menu didn't work, but the bottom menu, which is NOT inside a table, did work.
Still not clear..

Are you saying that CURRENTLY something PHP related is not working?

OR

Are you saying that it is a html issue that is / is not currently / previously working?

If its a html issue then this is the wrong forum. I looked at your source and performed a search for <? and found nothing.
__________________
Please wrap your code in [php] tags. It is a sticky topic and it HELPS us to HELP YOU!
TIP: Coding styles and $end errors :::::::::: TIP: Warning: Cannot modify header information - headers already sent :::::::::: TIP: Quotes / Parse error: syntax error, unexpected T_..
PHP Code:
//Please don't use this for your form processing:
if (isset($_POST['submit']))
//Internet explorer has a bug and does not always send the submit value. 
Explanation: The IE if(isset($_POST['submit'])) bug explained.
tangoforce is online now   Reply With Quote
Old 08-07-2012, 03:40 PM   PM User | #7
AndrewGSW
Senior Coder

 
Join Date: Apr 2011
Location: London, England
Posts: 2,120
Thanks: 15
Thanked 354 Times in 353 Posts
AndrewGSW will become famous soon enough
The links at the top don't work because you have gone overboard on the use of absolute, relative positioning (and using tables for layout!) and there is something sitting above the links preventing them from being clickable.

Ever wanted to see your page from the computer's perspective? But the attached image won't help you fix your page.
Attached Thumbnails
Click image for larger version

Name:	Image 7.jpg
Views:	29
Size:	45.8 KB
ID:	11429  
__________________
"I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.
Validate your HTML and CSS
AndrewGSW is offline   Reply With Quote
Old 08-07-2012, 04:09 PM   PM User | #8
countrydj
Regular Coder

 
Join Date: Nov 2011
Location: Preston, UK
Posts: 130
Thanks: 36
Thanked 0 Times in 0 Posts
countrydj is an unknown quantity at this point
Hi AndrewGSW

How did you do that ????

You have been a great help.
I now have something to work on.

Thanl you.
__________________
The MAN, The MYTH, The LEGEND:
John C
________________________________
Support your local Country Music Club
countrydj is offline   Reply With Quote
Old 08-07-2012, 04:37 PM   PM User | #9
AndrewGSW
Senior Coder

 
Join Date: Apr 2011
Location: London, England
Posts: 2,120
Thanks: 15
Thanked 354 Times in 353 Posts
AndrewGSW will become famous soon enough
Quote:
How did you do that ????
It's in FireFox - right click, Inspect Element (Q) and click the 3D View button. I'm not sure if it requires FireBug to be installed.
Attached Thumbnails
Click image for larger version

Name:	Image 8.jpg
Views:	20
Size:	53.6 KB
ID:	11430  
__________________
"I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.
Validate your HTML and CSS
AndrewGSW is offline   Reply With Quote
Old 09-08-2012, 11:54 PM   PM User | #10
tangoforce
Senior Coder

 
tangoforce's Avatar
 
Join Date: Feb 2011
Location: Your Monitor
Posts: 3,502
Thanks: 45
Thanked 439 Times in 428 Posts
tangoforce will become famous soon enoughtangoforce will become famous soon enough
Quote:
Originally Posted by AndrewGSW View Post
It's in FireFox - right click, Inspect Element (Q) and click the 3D View button.
Where do I find that? - I'm in Inspect Element (Q) but can't find any 3D button

Edit:
Nevermind, I don't have it and according to Mozilla its down to my graphics drivers
__________________
Please wrap your code in [php] tags. It is a sticky topic and it HELPS us to HELP YOU!
TIP: Coding styles and $end errors :::::::::: TIP: Warning: Cannot modify header information - headers already sent :::::::::: TIP: Quotes / Parse error: syntax error, unexpected T_..
PHP Code:
//Please don't use this for your form processing:
if (isset($_POST['submit']))
//Internet explorer has a bug and does not always send the submit value. 
Explanation: The IE if(isset($_POST['submit'])) bug explained.

Last edited by tangoforce; 09-09-2012 at 12:03 AM..
tangoforce is online now   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 11:50 AM.


Advertisement
Log in to turn off these ads.