CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Possible to load search page with "Edit Search Criteria" expanded?
Pages: [1]

Author Topic: Possible to load search page with "Edit Search Criteria" expanded?  (Read 685 times)

digitalzen

  • I post occasionally
  • **
  • Posts: 46
  • Karma: 0
Possible to load search page with "Edit Search Criteria" expanded?
June 01, 2010, 02:49:35 pm
Hello,

I'm working on a public search page (http://www.shorelinechamber.com/index.php?option=com_civicrm&task=civicrm/profile&force=1&gid=7), and would like the page to load with the "Edit Search Criteria" panel expanded, as users may not notice that the carrot is clickable. Is this possible? If so, how?

Thanks!
Chris

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Possible to load search page with "Edit Search Criteria" expanded?
June 01, 2010, 03:14:46 pm
I think you'll need to customize that template a bit - templates/Profile/Form/Search.tpl. Create a custom version using the instructions on the wiki:

http://wiki.civicrm.org/confluence/display/CRMDOC/Customize+Built-in%2C+Profile%2C+Contribution+and+Event+Registration+Screens

... and replace this:
Code: [Select]
<script type="text/javascript">
    {if empty($rows) }
var showBlocks = new Array("id_{$groupId}");
        var hideBlocks = new Array("id_{$groupId}_show");
    {else}
var showBlocks = new Array("id_{$groupId}_show");
        var hideBlocks = new Array("id_{$groupId}");
    {/if}
    {* hide and display the appropriate blocks as directed by the php code *}
    on_load_init_blocks( showBlocks, hideBlocks );
</script>

... with this
Code: [Select]
<script type="text/javascript">
var showBlocks = new Array("id_{$groupId}");
        var hideBlocks = new Array("id_{$groupId}_show");
    {* hide and display the appropriate blocks as directed by the php code *}
    on_load_init_blocks( showBlocks, hideBlocks );
</script>
Protect your investment in CiviCRM by  becoming a Member!

digitalzen

  • I post occasionally
  • **
  • Posts: 46
  • Karma: 0
Re: Possible to load search page with "Edit Search Criteria" expanded?
June 02, 2010, 12:32:20 am
Thanks, Dave! I'll give it a whirl.  :D

digitalzen

  • I post occasionally
  • **
  • Posts: 46
  • Karma: 0
Re: Possible to load search page with "Edit Search Criteria" expanded?
June 02, 2010, 09:15:08 pm
Worked like a charm! Thanks again, Dave!  ;D

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Possible to load search page with "Edit Search Criteria" expanded?

This forum was archived on 2017-11-26.