Forums / Developer / Search

Search

Author Message

justin kazadi

Wednesday 07 May 2008 7:19:06 am

Hello all,

I don't know why the search didn't work in my template. To have search i have write this:
"
<form action={"/content/search"|ezurl}>
<label for="searchtext" class="hide">Recherche:</label>
{if eq( $ui_context, 'edit' )}
<input id="searchtext" name="SearchText" type="text" value="" size="11" disabled="disabled" />
<input id="searchbutton" class="button-disabled" type="submit" value="{'Search'|i18n('design/ezwebin/pagelayout')}" alt="Submit" disabled="disabled" />
{else}
<input id="searchtext" name="SearchText" type="text" value="" size="14" />

<!-- supprimer<input id="searchbutton" class="button"
type="submit" value="{'Search'|i18n('design/ezwebin/pagelayout')}" alt="Submit" />
-->
<input id="searchbutton" class="button"type="submit" value="ok"/>
{if eq( $ui_context, 'browse' )}
<input name="Mode" type="hidden" value="browse" />
{/if}
{/if}
</form>

"
excuse me for my bad english.
Thanks in advance.

The theory is when we know everything and nothing works.
The practice is when everything works and nobody knows why.
If the practice and theory are met, nothing works and we do not know why.

Albert Einstein

Abdelkader RHOUATI

Wednesday 07 May 2008 7:31:12 am

Hi,

Note : if input is disabled, he will not be sended in your form, may be that's your problem,
try adding an input hidden!
tks

Abdelkader

Abdelkader RHOUATI

Blog (french) : http://arhouati.com
----
Extension arh_jdebug : EzDebug using jquery

justin kazadi

Thursday 08 May 2008 2:22:40 am

hi,
i have put disabled=enabled but the search don't work. and i have try enabled=enabled but nothing special.

The theory is when we know everything and nothing works.
The practice is when everything works and nobody knows why.
If the practice and theory are met, nothing works and we do not know why.

Albert Einstein

André R.

Thursday 08 May 2008 2:30:34 am

there is nothing called disabled="enabled" in html / xhtml.
But that is not your bug ( ref: "{if eq( $ui_context, 'edit' )}" code means that the search will only be disabled when you edit something).

your bug might be lack of whitespace between class and type 'class="button"type="submit"'!
Alternatively you are running fastcgi and need to use ' method="post"' on your form!

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

justin kazadi

Thursday 08 May 2008 4:32:18 am

hi,
i have done what you have says.now i have this :

<form action={"/content/search"|ezurl} method="post">
<label for="searchtext" class="hide">Recherche:</label>
{if eq( $ui_context, 'edit' )}

<input id="searchtext" name="SearchText" type="text" value="" size="11" disabled="disabled" />
<input id="searchbutton" class="button-disabled" type="submit"
value="{'Search'|i18n('design/ezwebin/pagelayout')}" alt="Submit" disabled="disabled" />
{else}
<input id="searchtext" name="SearchText" type="text" value="" size="14" />

<input id="searchbutton" class="button"
type="submit" value="{'Search'|i18n('design/ezwebin/pagelayout')}" alt="Submit" />

{if eq( $ui_context, 'browse' )}
<input name="Mode" type="hidden" value="browse" />
{/if}
{/if}
</form>
but the search didn't work.

The theory is when we know everything and nothing works.
The practice is when everything works and nobody knows why.
If the practice and theory are met, nothing works and we do not know why.

Albert Einstein

André R.

Thursday 08 May 2008 4:55:15 am

Works for me (when I past it into pagelayout).

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

justin kazadi

Thursday 08 May 2008 5:32:36 am

hi,
thanks you andré R for all. i want to know if search (and path)works only in pagelayout? it not possible to use it in a frontpage?.In my web site my pagelayout contains this:
"
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="{$site.http_equiv.Content-language|wash}" lang="{$site.http_equiv.Content-language|wash}">

<head>

<style type="text/css">
@import url({"stylesheets/soukstyle.css"|ezdesign(no)});
</style>

<title>kazadi dans le projet soukafrika</title>
</head>
<body><!--debut body-->
{$module_result.content}

</body><!--fin body-->
</html>
"
all the contents are in a frontpage (that i have overloaded).i think it the reason of this behavior.

The theory is when we know everything and nothing works.
The practice is when everything works and nobody knows why.
If the practice and theory are met, nothing works and we do not know why.

Albert Einstein

eZ debug

Timing: Jan 20 2025 14:31:48
Script start
Timing: Jan 20 2025 14:31:48
Module start 'content'
Timing: Jan 20 2025 14:31:49
Module end 'content'
Timing: Jan 20 2025 14:31:49
Script end

Main resources:

Total runtime1.5170 sec
Peak memory usage4,096.0000 KB
Database Queries208

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0063 589.7734180.8594
Module start 'content' 0.00631.3530 770.6328658.5078
Module end 'content' 1.35920.1577 1,429.1406345.0938
Script end 1.5170  1,774.2344 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00630.4159210.0003
Check MTime0.00150.0973210.0001
Mysql Total
Database connection0.00070.047710.0007
Mysqli_queries1.405092.61812080.0068
Looping result0.00240.16012060.0000
Template Total1.489098.220.7445
Template load0.00200.131020.0010
Template processing1.487098.021220.7435
Template load and register function0.00010.006710.0001
states
state_id_array0.00110.072010.0011
state_identifier_array0.00080.051620.0004
Override
Cache load0.00190.1254900.0000
Sytem overhead
Fetch class attribute can translate value0.00180.118140.0004
Fetch class attribute name0.00130.0884100.0001
XML
Image XML parsing0.00370.243140.0009
class_abstraction
Instantiating content class attribute0.00000.0017140.0000
General
dbfile0.00960.6305400.0002
String conversion0.00000.000530.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
7content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
7content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
14content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
11content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 41
 Number of unique templates used: 6

Time used to render debug report: 0.0002 secs