coppermine-gallery.com/forum

Support => Older/other versions => cpg1.3.x Support => Topic started by: UK10 on June 11, 2005, 07:17:22 PM

Title: Help me with developing the Addon (Advance Search Feature)
Post by: UK10 on June 11, 2005, 07:17:22 PM
I am trying to develop this (http://uk10.allhyper.com/album/search.php) and get it to work

Currently the code looks like this:

<?php
/*************************
  Coppermine Photo Gallery
  ************************
  Copyright (c) 2003-2005 Coppermine Dev Team
  v1.1 originaly written by Gregory DEMAR

  This program is free software; you can redistribute it and/or modify
  it under the terms of the GNU General Public License as published by
  the Free Software Foundation; either version 2 of the License, or
  (at your option) any later version.
  ********************************************
  Coppermine version: 1.3.3
  $Source: /cvsroot/coppermine/stable/search.php,v $
  $Revision: 1.6 $
  $Author: gaugau $
  $Date: 2005/04/19 03:17:11 $
**********************************************/

define('IN_COPPERMINE'true);
define('SEARCH_PHP'true);

require(
'include/init.inc.php');

pageheader($lang_search_php[0]);

starttable(500$lang_search_php[0]);
echo <<< EOT
        <tr>
                <form method="get" action="thumbnails.php" name="searchcpg">
               <input type="hidden" name="album" value="search">
               <input type="hidden" name="type" value="full">
        <td class="tableb" align="center" height="60">
                <select name="search" size="1">
            <option selected>Aircraft</option>
          <option>All the content of user1</option>
        </select>
                </td>
        <tr><td class="tableb" align="center" height="60">
                <select name="search" size="1">
            <option selected>Airline</option>
          <option>All the content of user2</option>
        </select>
                 </td>
                        <script language="javascript" type="text/javascript">
                        <!--
                        document.searchcpg.search.focus();
                        -->
                        </script>
        </tr>
        <tr>
                <td colspan="8" align="center" class="tablef">
                        <input type="submit" value="
{$lang_search_php[0]}" class="button">
                </td>
                </form>
        </tr>

EOT;
endtable();
pagefooter();
ob_end_flush();

?>


Where I say "All the content of user 1" I mean that the code will look in the database for all the different entries under user 1 and put them in the list.

Greetz,
   Daniel

/Edit Updated Code
Title: Re: Help me with developing the Addon (Advance Search Feature)
Post by: havoc615 on June 13, 2005, 03:36:51 AM
Hey! I'd love to help out with this, can you give me a little more backround on what you want it to do?

Also, if you changed it can you update the code, because I don't even see 72 lines there
Title: Re: Help me with developing the Addon (Advance Search Feature)
Post by: UK10 on June 13, 2005, 08:24:17 PM
Quote from: havoc615 on June 13, 2005, 03:36:51 AM
Hey! I'd love to help out with this, can you give me a little more background on what you want it to do?

Yes, what I am wanting to do is have 2 or 3 Drop down menus(Might add Location) which op the content is populated by MYSQL database.

Quote from: havoc615 on June 13, 2005, 03:36:51 AMAlso, if you changed it can you update the code, because I don't even see 72 lines there

That was not actualy my version, I have updated the code in my message as well as on my server, what you seen was a Mod which I found in this (http://forum.coppermine-gallery.net/index.php?topic=11272.0) topic.
Title: Re: Help me with developing the Addon (Advance Search Feature)
Post by: havoc615 on June 13, 2005, 08:29:58 PM
Ok, thats the problem, no one but you can get to the php code on your server, because php is all server side. So if you can IM me or something, maybe we can work on something.

SO are you searching for pictures posted by a user? Or maybe comments made by a user? What goes in the boxes? etc.