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";

No comments posted yet

Your Answer:

Login to answer
326 Like 10 Dislike
Previous forums Next forums
Other forums

Wrong Info sent Using $get in form
Hi i have this code that i tried to make to send some info from one page to aother with lots of ppls

Passing an array of values From VB6.0 to Oracle PL/SQL Function
Basically we are using VB6.0.

When we try to pass an array from VB6.0 to an Oracle PL/SQL

Firewall / visited websites logger
Hi. I have a firewall implementation and I want to log all the websites visited on the machine. S

Session is not saving
I am not trying to do anything too fancy, I am just trying to get some $_SESSION data to save and us

onClick='location.href=index.htm'> not working
Below is my code:

echo "<input type='button' value='redirect' onClick='location.h

i have no idea why this isn't working
Code: <?php
session_start();
include("connect.php");

error_reporting(E

form help
this doesn't work. i want the form action to go the location.href of the submit button chosen.. how

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

Blank record injected into database
I always found several blank records inside my database, although $SESSION is required to insert the

Calander Basic Spript help
hi, just starting out with PHP and have the following script:

<?php
//This gets t

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