Parse Error


Posted on 16th Feb 2014 07:03 pm by admin

Hi Guys,

I have a function in my class which returns a string link variable. The problem is it keeps giving me a parse error. See code below followed by error message:

Code: function get_previouspage_link()
{
if($this->CURRENT_PAGE > 1)
$previous_page = $this->CURRENT_PAGE - 1;
return "$_SERVER['REMOTE_URI']?currentpage=$previous_page";
}
Code: Parse error: parse error, expecting `T_STRING' or `T_VARIABLE' or `T_NUM_STRING' in C:wampwwwwordpresswp-contentthemesalburujpresspaginate.php on line 50

LINE 50: return "$_SERVER['REMOTE_URI']?currentpage=$previous_page";

326 Like 10 Dislike
Previous php-forum Next php-forum
Other php-forum

Using mysql_real_escape_string for displayed content
On my website users can input data into a textarea and it will store it in the mysql database. But,

Running a cron job through PHP/Apache?!
Hello all,
I have a PHP script which makes a cron file from user input. When i try to run the cro

Google voice
I currently have a form in html, but I want it in php so the information is not in the source code.<

Default TimeZone
The server I'm working with is hosted in America so all times inserted into the database are coming

Save User Inputs while javascript reloading!
hi..
i have written a PHP code in which i reload the page when user selects a value in dropdown..

update sql when refresh - php
hi
I have made a table (attachement)

the users can update the sql database using + or x bu

need help with php get
i have a option box that gets filled with dates, but how do i get once the option value has been cli

Adding post count
How would I make it so everytime someone clicks submit on my form, their row in the database for the

A little help needed passing hidden values to next page
I have a page that has hidden values in a form.

example
Code: <input name='signupID

textfield unchanged
hi,
i want my form to know whether its textbox is unchange or not.

if($textbox == 'unchang

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash