PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
Moderator: General Moderators
pleigh
Forum Contributor
Posts: 445 Joined: Wed Jan 19, 2005 4:26 am
Post
by pleigh » Tue Feb 14, 2006 12:25 am
can someone help me with this...i want to use the asp-style tag for php, i tried to run a simple code
Code: Select all
<% echo 'you may optionally use ASP-style tags' ; %>
i also turned "on" the asp_tags in my php.ini...when i tried to browse it, the same code appears and it does not execute..pls help.
many thanks.
Last edited by
pleigh on Tue Feb 14, 2006 1:16 am, edited 1 time in total.
feyd
Neighborhood Spidermoddy
Posts: 31559 Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA
Post
by feyd » Tue Feb 14, 2006 12:44 am
did you remember to restart your web server? did you edit the wrong php.ini file?
josh
DevNet Master
Posts: 4872 Joined: Wed Feb 11, 2004 3:23 pm
Location: Palm beach, Florida
Post
by josh » Tue Feb 14, 2006 12:44 am
Did you restart apache after making those changes to your php.ini (if you use apahce...)
Can you post the relevant line out of your php.ini just so we can check your work?
~~~~
edit: feyd beat me
pleigh
Forum Contributor
Posts: 445 Joined: Wed Jan 19, 2005 4:26 am
Post
by pleigh » Tue Feb 14, 2006 12:50 am
oops...never thought of that..
i'll give it a try...thanks guys..
pleigh
Forum Contributor
Posts: 445 Joined: Wed Jan 19, 2005 4:26 am
Post
by pleigh » Tue Feb 14, 2006 12:54 am
hi, never worked when i restarted apache...below are the lines i think relevant to this
; Allow ASP-style <% %> tags.
asp_tags = On
i turned it On already....oh, by the way, i am using xampp for this...so there are 2 .ini files, i turned them both On (the asp_tags)
josh
DevNet Master
Posts: 4872 Joined: Wed Feb 11, 2004 3:23 pm
Location: Palm beach, Florida
Post
by josh » Tue Feb 14, 2006 1:01 am
The next step would be to post the output of phpinfo()
pleigh
Forum Contributor
Posts: 445 Joined: Wed Jan 19, 2005 4:26 am
Post
by pleigh » Tue Feb 14, 2006 1:12 am
i'm confused now...i already turned enabled the asp_tags in my ini file, but why is it in my phpinfo(), it is not enabled...local and master values are set to Off...help pls..
pleigh
Forum Contributor
Posts: 445 Joined: Wed Jan 19, 2005 4:26 am
Post
by pleigh » Tue Feb 14, 2006 1:16 am
its ok now, i edited the ini file located inside the apache folder...restarted the web server, and its good to go..thanks for the idea.
AKA Panama Jack
Forum Regular
Posts: 878 Joined: Mon Nov 14, 2005 4:21 pm
Post
by AKA Panama Jack » Tue Feb 14, 2006 3:09 am
pleigh wrote: hi, never worked when i restarted apache...below are the lines i think relevant to this
; Allow ASP-style <% %> tags.
asp_tags = On
i turned it On already....oh, by the way, i am using xampp for this...so there are 2 .ini files, i turned them both On (the asp_tags)
If this is the windows version of XXAMP you need to edit the php.ini in the apache/bin directory. There are 4 different php ini files.
Jenk
DevNet Master
Posts: 3587 Joined: Mon Sep 19, 2005 6:24 am
Location: London
Post
by Jenk » Tue Feb 14, 2006 5:14 am
Whilst you are still able to make the choice, using ASP tags for PHP is discouraged