Load the cloud before any action
This commit is contained in:
parent
3ff96924fb
commit
76ab05c8c7
3 changed files with 22 additions and 33 deletions
|
@ -4,12 +4,12 @@ include('templates/header.php');
|
|||
|
||||
if (isset($_GET['id'])) {
|
||||
$id = $_GET['id'];
|
||||
if (!$db->isCloud($id)) {
|
||||
if (!$db->loadCloud($id)) {
|
||||
echo L::cloud_noId;
|
||||
return;
|
||||
}
|
||||
$nbWords = $db->getCloudSize($id);
|
||||
echo sprintf('<p class="cloud_text">%s</p>', $db->getCloudText($id));
|
||||
$nbWords = $db->getCloudSize();
|
||||
echo sprintf('<p class="cloud_text">%s</p>', $db->getCloudText());
|
||||
?>
|
||||
<form class="cloud_words" method="post" action="save.php">
|
||||
<input type="hidden" id="fid" name="fid" value="<?php echo $id;?>">
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue