Gossamer Forum
Home : Products : Gossamer Links : Discussions :

Multiple Modify Form for Multiple Add Form

Quote Reply
Multiple Modify Form for Multiple Add Form
Hello all,

For the information, i'm using the global tag i attach in this thread to make a multiple add form for multiple category, the problem now is on modification, how to make the link will using/recognise the modify form same as addition.

For example i was add a link by using 'add_announ.html' on category 'Announcement', but how if i want to make a modication it will using the same form, sorry to my english and please help.

custom_form =>
sub {
my $tags = shift;
my $query = $tags->{query};
my ($full_name) = $DB->table('Category')->select(['Full_Name'], { ID => $tags->{ID} })->fetchrow;
my $file = '';
if ($full_name =~ /^Announcements/) {
$file = 'add_announ.html';
}
elsif ($full_name =~ /^Automobiles/) {
$file = 'add_auto.html';
}
elsif ($full_name =~ /^Business_Opportunities/) {
$file = 'add_buss.html';
}
elsif ($full_name =~ /^Collectibles/) {
$file = 'add_collect.html';
}
elsif ($full_name =~ /^Computers___Software/) {
$file = 'add_computer.html';
}
elsif ($full_name =~ /^Employment/) {
$file = 'add_employ.html';
}
elsif ($full_name =~ /^General_Merchandise/) {
$file = 'add_general.html';
}
elsif ($full_name =~ /^Lost___Found/) {
$file = 'add_lost.html';
}
elsif ($full_name =~ /^Personals/) {
$file = 'add_personal.html';
}
elsif ($full_name =~ /^Professional_Services/) {
$file = 'add_services.html';
}
elsif ($full_name =~ /^Real_Estate/) {
$file = 'add_real.html';
}
elsif ($full_name =~ /^Rentals___Roommates/) {
$file = 'add_rental.html';
}
..
else {
$file = 'include_form.html';
}
open (FILE, "/home/worldbar/public_html/db/cgi-bin/admin/templates/default/$file");
read (FILE, my $data, -s FILE);
close FILE;
return $data;
}

Last edited by:

reenee: Feb 21, 2002, 1:38 PM
Quote Reply
Re: [reenee] Multiple Modify Form for Multiple Add Form In reply to
Somebody Help me please ....
Quote Reply
Re: [reenee] Multiple Modify Form for Multiple Add Form In reply to
Please Help ? Anobody ?
Quote Reply
Re: [reenee] Multiple Modify Form for Multiple Add Form In reply to
Hello Reenee, Hello everybody,




I am trying to do the same thing and am having the same problem.
Also, I am having another issue that you didn't mention:

I tried this with setup>user>db_gen_category_list (both set to yes and then to no)
The custom add form does not seem to use the <% cathegory %> tag, because the server script

keeps teeling me that I didn't set a cathegory for the link. Since the other tags (<%if Title%><%Title%><%endif%> etc.)

display in the text fields instead of being parsed, this is likely to be caused bu the same problem.

Can anyone share some information with me?

Last edited by:

nt6: Mar 15, 2002, 2:30 AM
Quote Reply
Re: [nt6] Multiple Modify Form for Multiple Add Form In reply to
Could someone reply to me. I am still not able to customize my add link form.

Thank you for your time.
Quote Reply
Re: [nt6] Multiple Modify Form for Multiple Add Form In reply to
Hi,

The change to modify should be the same as that to add. What is the problem you are having?

Cheers,

Alex
--
Gossamer Threads Inc.
Quote Reply
Re: [Alex] Multiple Modify Form for Multiple Add Form In reply to
Hi Alex,

I am sorry my explanation was not clear.

I know what the problem is now, for some reason when I use the custom_form global, the custom add form that comes up has everything that should be updated 'on the fly' on screen without having been parsed. Ex: everything from the <%body_font%> tag to the <%Category%> tag is just returned as is instead of being replaced by it's value. That's why I am having trouble adding and modifying content. The custom form is coming up in each category, but is not processing all the dynamic content.

I have never seen this problem in links. Any ideas?

Links SQL is a great product. All I will need to do once this issue is solved is modify my detailed page with the same kind of global! Something like <%Custom_detailed%> so that based on the category, I get a specific detailed page. I love it.
Quote Reply
Re: [nt6] Multiple Modify Form for Multiple Add Form In reply to
Hello nt6,

I have a problem with the Global.

It cannot use the tags.
<%if Title%><%Title%><%endif%>
<%if URL%><%URL%><%else%>http://<%endif%>
...

They are displayed in the fields.

You found a response to your problem?

Thank you for your assistance.

Mick