Commit e53f959e authored by jlaval's avatar jlaval
Browse files

Boulettage de $site

parent a7d7c9ac
...@@ -491,7 +491,7 @@ class catphoto extends basedb ...@@ -491,7 +491,7 @@ class catphoto extends basedb
$this->meta_cat = &$meta_cat; $this->meta_cat = &$meta_cat;
} }
function remove_cat() function remove_cat($site)
{ {
$req = new requete($this->db, $req = new requete($this->db,
"SELECT * FROM sas_photos " . "SELECT * FROM sas_photos " .
...@@ -512,7 +512,7 @@ class catphoto extends basedb ...@@ -512,7 +512,7 @@ class catphoto extends basedb
while ( $row = $req->get_row() ) while ( $row = $req->get_row() )
{ {
$cat->_load($row); $cat->_load($row);
$cat->remove_cat(); $cat->remove_cat($site);
} }
$sql = new delete($this->dbrw,"sas_cat_photos",array("id_catph"=>$this->id) ); $sql = new delete($this->dbrw,"sas_cat_photos",array("id_catph"=>$this->id) );
......
...@@ -204,7 +204,7 @@ elseif ( $_REQUEST["action"] == "delete" && $cat->is_valid() && !$_REQUEST["id_p ...@@ -204,7 +204,7 @@ elseif ( $_REQUEST["action"] == "delete" && $cat->is_valid() && !$_REQUEST["id_p
{ {
if ( $site->is_sure ( "","Suppression de la catégorie ".$cat->nom,"ctph".$cat->id, 3 ) ) if ( $site->is_sure ( "","Suppression de la catégorie ".$cat->nom,"ctph".$cat->id, 3 ) )
{ {
$cat->remove_cat(); $cat->remove_cat($site);
$cat->load_by_id($cat->id_catph_parent); $cat->load_by_id($cat->id_catph_parent);
} }
} }
......
...@@ -158,7 +158,7 @@ elseif ( $_REQUEST["action"] == "moderecat" ) ...@@ -158,7 +158,7 @@ elseif ( $_REQUEST["action"] == "moderecat" )
{ {
if ( isset($_REQUEST["delete"])) if ( isset($_REQUEST["delete"]))
{ {
$catmod->remove_cat(); $catmod->remove_cat($site);
} }
else else
{ {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment