Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Your question isn't complete and not specifying your problem. I am assuming that you need to know how to do it. In which case, you will probably be doing something like following,</p> <ol> <li><p>As soon as the user saves the page, you will be storing that information in some kind of database, that information will tell you which image to show.</p></li> <li><p>When you open the home page, just go to database and check if a record for that page exists in database. If it does then show tick else show cross.</p></li> </ol> <p><strong>UPDATE:</strong> </p> <p>You will run a select query. eg. Your table is PAGE and page name is "page1" (or any other field that identifies the page uniquely.) Your query will be soemthing like,</p> <p>"SELECT complete From PAGE where Unique_Field = 'unique_page_field'"</p> <p>And then you would have an if check, check if complete == 1 then show tick else show cross.</p> <p>If you have a really large collection of pages then instead of hitting database for every page, you can run one single query, such as SELECT complete, Unique_Field From PAGE and for every page, you will just check this collection for given record. So if given page is in the collection then show tick else show cross.</p> <p><strong>UPDATE For IF Statement:</strong> Assuming you will go for first approach : </p> <ol> <li>You ran the query : "SELECT complete From PAGE where Unique_Field = 'unique_page_field'"</li> </ol> <p>and now you have the value in $isComplete variable, here's what you will do in your HTML side code,</p> <pre><code>&lt;img src='&lt;?php if($isComplete) echo "tick.jpg"; else echo "cross.jpg"; ?&gt;' /&gt; </code></pre> <p>make sure that your image paths are correct.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload