Search and default landing page

6 views
Skip to first unread message

Brian A. Rellinger

unread,
Aug 1, 2011, 1:05:08 PM8/1/11
to UNL Event Publisher
Two items - we are going live with the most likely in the next couple
of weeks, but the search is not working for some reason. It *was*
working at one point, but no longer. Every search returns no
results. Below is a link and the code from the Frontpage template
file. The search tip box does not work either.

http://owuevents.owu.edu/

Second item - any way to make the default page the upcoming events
instead of today's events?

<form id="event_search" name="event_search" method="get" action="<?php
echo UNL_UCBCN_Frontend::formatURL(array('calendar'=>$this->calendar-
>id,'search'=>'search')); ?>">

<input type='text' name='q' id='searchinput' alt='Search
for events' value="" />
<input type='submit' name='submit' value="Search" />
<input type='hidden' name='search' value='search' />
<p id="search_term">Search smartly: In addition to normal
keyword search, you can also search with chronological terms such as
'tomorrow', 'Monday' and etc.
<a href="#" title="close search tip">(close message)</a>
</p>

Brett Bieber

unread,
Aug 1, 2011, 3:00:13 PM8/1/11
to unl-event...@googlegroups.com
On Mon, Aug 1, 2011 at 12:05 PM, Brian A. Rellinger <bare...@owu.edu> wrote:
Two items - we are going live with the most likely in the next couple
of weeks, but the search is not working for some reason.  It *was*
working at one point, but no longer.  Every search returns no
results.  Below is a link and the code from the Frontpage template
file.  The search tip box does not work either.

http://owuevents.owu.edu/


It looks like your frontend URI isn't configured correctly. The XHR request fires off to:
http://owuevents.owu.edu/?&?q=Fish&format=hcalendar&search=search

When it should be:
http://owuevents.owu.edu/?q=Fish&format=hcalendar&search=search

Look at the console in Firebug or Chrome and you should be able to see the requests.
 
Second item - any way to make the default page the upcoming events
instead of today's events?

Hmm, I think you could do this with a rewrite rule, but it might take some testing since you're using the querystring URI format instead of REST formatted URLs.

I was thinking something like:
RewriteEngine On
RewriteCond %{QUERY_STRING} ^$
RewriteRule ^$ ?upcoming


--
Brett Bieber
University of Nebraska-Lincoln

Brian A. Rellinger

unread,
Aug 3, 2011, 3:07:59 PM8/3/11
to UNL Event Publisher
Thanks, I see that URL's you referenced now...but where would I go to
affect that?

Much appreciated....
b

On Aug 1, 3:00 pm, Brett Bieber <brett.bie...@gmail.com> wrote:

Brett Bieber

unread,
Aug 3, 2011, 4:50:36 PM8/3/11
to unl-event...@googlegroups.com
The frontend javascript builds the appropriate request URI when you click the submit button.

Inside the frontend.js, there's a method ajaxsearch(). You may need to modify the formAction variable, or modify your action="..." within your HTML. The frontend.js was built for sites using the REST based URLs, which is a configuration option passed to the frontend constructor.

Hope that helps.

--
You received this message because you are subscribed to the Google Groups "UNL Event Publisher" group.
To post to this group, send email to unl-event...@googlegroups.com.
To unsubscribe from this group, send email to unl-event-publi...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/unl-event-publisher?hl=en.

Brian A. Rellinger

unread,
Aug 12, 2011, 2:22:45 PM8/12/11
to UNL Event Publisher
Ok, so maybe my Frontend.tpl was referencing some files outside of the
"working" template directory, so my changes were having no impact.
And maybe I corrected that and things magically started working.......

Unrelated question, is there a way to link to events with a specific
event type? For example, select * from eventcal.event_has_eventtype
where eventtype_id=3? A general search works somewhat, but then you
may also get Lectures that have the word "Arts" in the description, so
I'm looking for a way to pull only based on the eventtype.

Thanks for the help. We go live next week in production: http://owuevents.owu.edu
b

On Aug 3, 4:50 pm, Brett Bieber <brett.bie...@gmail.com> wrote:
> The frontend javascript builds the appropriate request URI when you click
> the submit button.
>
> Inside the frontend.js, there's a method ajaxsearch(). You may need to
> modify the formAction variable, or modify your action="..." within your
> HTML. The frontend.js was built for sites using the REST based URLs, which
> is a configuration option passed to the frontend constructor.
>
> Hope that helps.
>

Brett Bieber

unread,
Aug 15, 2011, 9:47:56 AM8/15/11
to unl-event...@googlegroups.com
On Fri, Aug 12, 2011 at 1:22 PM, Brian A. Rellinger <bare...@owu.edu> wrote:
> Unrelated question, is there a way to link to events with a specific
> event type?  For example, select * from eventcal.event_has_eventtype
> where eventtype_id=3?  A general search works somewhat, but then you
> may also get Lectures that have the word "Arts" in the description, so
> I'm looking for a way to pull only based on the eventtype.

I believe someone had build another view for event type searches, or
simply modified the SQL to look for specific keywords in the query.
?q=type:meeting for example. I'm not sure though.

It's not something we've tackled here, yet.

> Thanks for the help.  We go live next week in production:  http://owuevents.owu.edu

Reply all
Reply to author
Forward
0 new messages