Quick Syntax Question


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

Hi folks,

I'm getting the following error: "unexpected T_LNUMBER". I'm trying to build a dynamic table in PHP it was working great until I attempted to include a java reference in one of my links. A watered down version of the code is as follows:

Code: $apps_html = '<table>';
$apps_html.= '<tr class="tableHeader">';
$apps_html.= '<th scope="col">VIEW</th>';
$apps_html.= '<th scope="col">TITLE</th>';
$apps_html.= '<th scope="col">DATE MODIFIED</th>';
$apps_html.= '<th scope="col">STATUS</th>';
$apps_html.= '<th scope="col">EDIT</th>';
$apps_html.= '<th scope="col">DELETE</th>';
$apps_html.= '</tr>';
$apps_html.= '<tr class="tablerow2">';
$apps_html.= '<td><a href="link.php">view</a></td>';
$apps_html.= '<td>' . $var1 . '</td>';
$apps_html.= '<td>' . $var2 . '</td>';
$apps_html.= '<td>' . $var3 . '</td>';
if($var1 == 'PENDING'){
$apps_html.= '<td><a href="delete.php">delete</a></td>';
}else{
$apps_html.= '<td><a href="window.html" onclick="popUp(this.href,'200','400'); return false;"></a></td>';
}
$apps_html.= '</tr>';
$apps_html.= '</table>';
The document body looks something like this:
Code: <html>
<head>
<title>I hate java</title>
</head>
<body>
<?php echo $apps_html; ?>
</body>
</html>

The problem is with this line obviously:
Code: $apps_html.= '<td><a href="window.html" onclick="popUp(this.href,'200','400'); return false;"></a></td>';
Can anyone help me with the correct syntax to include java variables in my href? Thanks for your time!

No comments posted yet

Your Answer:

Login to answer
68 Like 18 Dislike
Previous forums Next forums
Other forums

Is it a good practice to store user info. in sessions?
I am making a user class for my script which stores all the user information in sessions. It takes u

Backflush
I am looking for a report in SAP that would give me a list of all parts that are populated with a ba

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

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

Need help urgant
why down my code ony return one item instead of all the items selected.

$arr = array($date,$

Production Order Enterprise Service to Manufacturing Exctn Sys (MES) ???
Hello Experts,

In our current landscape SAP ECC 5.0 is integrated to MES system via PI 7.

How to schedule the a job?
Hi,
I have prepared a task ( i.e. a procedure is prepare the file and send the same to con

asking for direction
I have 2 tables in my data, which are "post" and "event"
I won't make a summa

count only commas outside parenteses
I have a sql table containing
id - query - query name
the first page contains a drop down men

Casting Decimals in Oracle
This code worked as a query in DB2, but I am not sure what the syntax is for casting decimals in Ora

restricting another login once you logout
Hello,

how can I restrict a page from login authenticating against info in a MySQL DB for a s

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