The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
renaming $
$sql = "SELECT count(*) FROM uploadimages";
$sql2 = mysql_query($sql); $id2 = mysql_result($sql2); $id = $id2 + 1; ----- This is not for mysql... though there is a mysql_query later using auto_increment. ^^ As i said though its for variable |
#2
|
||||
|
||||
What's the problem - not quite following as you haven't said what problem you're encountering or what you're trying to do
|
#3
|
|||
|
|||
Basically...
it renames the file dependant on an id.... its easily added due to mysql's auto increment, but i want to rename the file before hand, so i want a query getting latest id then when done ill add a 1. |
#4
|
||||
|
||||
You mean for example when you add something to the database you want to get the id that was just created assosciated with that record? If so use mysql_insert_id
|
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|