Tags:
create new tag
view all tags

Question

I have several data objects in one web - each object has it's own form (to define fields) and new ones are created using each object's template (to provide default values).

I would like the user to have different functionality when they view each of the two object types. Say on one, they would have a SEARCH list based on something relevant to that object. In the other a different SEARCH list and say some functionality to create a NEW topic. Fine. This all works great when I put the code in the Topic (based on the object's template, using that objects form.)

The newbie part here is that when I put this functionality in the template - the user sees the code for the SEARCH (and can of course mess it up.) Putting this in the form doesn't do anything.

Where do I put this SEARCH code? (I'm guessing I need custom tmpl code buried somewhere...)

p.s. I would like the code to be different for view vs. edit.

Thanks for all the help!

Environment

TWiki version: TWikiRelease04x02x00
TWiki plugins: DefaultPlugin, EmptyPlugin, InterwikiPlugin
Server OS: Vista
Web server: Apache
Perl version:  
Client OS: Vista
Web Browser: Chrome
Categories: Forms, Search, Javascript, Skin

-- PeterGaston - 25 Sep 2008

Answer

ALERT! If you answer a question - or someone answered one of your questions - please remember to edit the page and set the status to answered. The status selector is below the edit box.

Couldn't you place the search in a separate topic and use the ParameterizedIncludes technic to include the parameterized search in your template topic? So the users won't mess up the search so easily. You can even restrict access to the topic including the search without using functionality. On the contrary, the application gets much more maintainable.

-- FranzJosefGigler - 26 Sep 2008

Definitely a sweet suggestion for making the code more maintainable.

However, the key question is if I can make it so the user doesn't see the code that drives the ParameterizedIncludes . The way I'm doing it - this shows up as part of the rich text area that they edit (when they create or edit a topic.)

Thanks!!!

-- PeterGaston - 26 Sep 2008

Good 'nuff for now - Thanks!

-- PeterGaston - 29 Sep 2008

Change status to:
Edit | Attach | Watch | Print version | History: r4 < r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r4 - 2008-09-29 - PeterGaston
 
  • Learn about TWiki  
  • Download TWiki
This site is powered by the TWiki collaboration platform Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2026 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.