Jump to content

is this query string correct


deansaddigh

Recommended Posts

The html is being produced invalidly, so this may help

 

echo '<a href="list_courses.php?id='.$row['course_id'].'"><p>'. $row['type']. ' :'.$row['course_name'].'</p></a><hr />';

 

personally I prefer to use sprintf to build strings from pieces, or here use printf.

I just find it easier to read

printf("<a href=\"list_courses.php?id=%d\"><p>%s:%s</p></a><hr>",$row['course_id'],$row['type'],$row['course_name']);

I see thanks for your help.

 

Unfortunately its still just closing the box even with your revisions, i believe its because its within

<div id="caja">';

 

which is what i am using so the box expands to display all the courses related to that school

 

and i beleive this bit of functionality,

 

$("#mostrar").click(function(event) {
event.preventDefault();
$("#caja").slideToggle();
});

$("#caja a").click(function(event) {
event.preventDefault();
$("#caja").slideUp();
});
});

 

uses any link within the caja div make the box expand.

 

Which is fine if i have normal text init but because im using a link it takes the expand function.

 

Do you know a way i can get around this?

 

I hope that made some sense

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.