very intersting Variable question
The function calls one variable, which then needs to be placed inside other Session variables to be useful. Dig it >>
--------
function new_sql($object) {
$scratch_id = get_scratch();
$section = $object . "s";
$sql = "INSERT INTO $_SESSION[schema_table]
(
user_id, scratch_id,
entry_type,
content_type, content_subtype, content_label,
urlpath, pagename, section,
title, content, content_format,
collection_array,
order_pref, status
)
VALUES
(
'69', '$scratch_id',
'collection', 'article', '$object', '$_SESSION[new_{$object}_label]',
'$_SESSION[new_{$object}_urlpath]', '$_SESSION[new_{$object}_label]', '$section',
'$_SESSION[new_{$object}_title]', 'TO BE ADDED', 'plain',
'$_SESSION[brand_new_collection_array]',
'title', 'public'
)
";
mysql_query($sql) or die(mysql_error());
} // end function
I'm getting a parse error, for what should be obvious reasons... but do you get the gist of where I need to go with this?
An $object = "issue" or $object = "article" something like that...
Reduce stress | Stay focused | Keep positive and balanced