happyboating Posted May 21, 2010 Share Posted May 21, 2010 I have php 5 set on the two domains I am using. One domain has the script and is passing the keyword which is supposed to dynamically insert into the output page. Let's say the keyword is rice. The php should execute so the word rice should appear on the output page. Problem is the code doesnt seem to execute and nothing happens. It is simple code. The scripts tells me to simply insert <?=$_REQUEST['kwd']?> whereever you want the keyword to appear (in this case rice is the keyword) I have also tried the <?php echo REQUEST['kwd']; ?> and that doesn't seem to work either. To test, first go to http://downloadablemusicfree.net/AP/go.php?uid=1&cid=7&id=rice The output page will look like this: http://ovariancancerprognosis.org/test.html?apid=A100008O and you will see rice doesn't appear in the title. Thank you for your help. Quote Link to comment https://forums.phpfreaks.com/topic/202522-why-wont-this-php-execute/ Share on other sites More sharing options...
premiso Posted May 21, 2010 Share Posted May 21, 2010 Not sure if this was just your typo, but this would be the better way to echo it, as <?= requires short_open_Tags to be on in the php.ini <?php echo $_REQUEST['kwd']; ?> But given that this is displayed in the title: <title>Your Site - <?php echo REQUEST['kwd']; ?></title> PHP is not being parsed by your server / your server is not setup to handle PHP requests. Quote Link to comment https://forums.phpfreaks.com/topic/202522-why-wont-this-php-execute/#findComment-1061669 Share on other sites More sharing options...
Psycho Posted May 21, 2010 Share Posted May 21, 2010 Something is changing your code. This is the ACTUAL code in your page: <title>Your Site - <?php echo REQUEST['kwd']; ?></title> So, somehow the < > are changed to their HTML codes of < > Quote Link to comment https://forums.phpfreaks.com/topic/202522-why-wont-this-php-execute/#findComment-1061685 Share on other sites More sharing options...
ScotDiddle Posted May 21, 2010 Share Posted May 21, 2010 happyboating, Try saving your file "test.html" as "test.php" then run: http://ovariancancerprognosis.org/test.php?apid=A100011O That may be all that's needed. Scot L. Diddle, Richmond VA Quote Link to comment https://forums.phpfreaks.com/topic/202522-why-wont-this-php-execute/#findComment-1061708 Share on other sites More sharing options...
Mchl Posted May 21, 2010 Share Posted May 21, 2010 http://www.phpfreaks.com/forums/index.php/topic,298648.msg1414160.html#msg1414160 Quote Link to comment https://forums.phpfreaks.com/topic/202522-why-wont-this-php-execute/#findComment-1061771 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.