Gossamer Forum
Home : Products : Gossamer Links : Version 1.x :

Links as homepage-generator

Quote Reply
Links as homepage-generator
Have thought about the following:
Add some new fields for textblocks and grafix, and a detailed (yes/No) and one for the format (1,2,3,4) and a htmlname as textvar.
When adding set detailed to no as hidden field, the same when modifying. Change the dir Detailed to the main dir, so the detailed-page is created in http://www.domain.com/...
Instead of building ID.html build html-name.html.
In Detailed.html do if format = 1 do text1, pic1 text 2 pic 2 ... if format = 2 made a table 2on2 or something like this.

Now my probs at the moment:
1. How to prevent users from entering a value in htmlname that is used from another user. (Maybe with UNIQUE in SQL?)
2. Its clear how to build the detailed only when the Detailed is set to yes; but how can i change the field to no after or while building so the page isnt build a second time without modifying? (In my intranet i need 4 seconds to build for 100 Detaileds) So some function like: change all fields Detailed in all entrees that are yes to no.

Fine idea, isnīt it?
Hope to hear from you, maybe with some other fine sugestmens to improve this.
Robert

Quote Reply
Re: Links as homepage-generator In reply to
I"m not sure the 1.11 version is up to this.

The next version might be.

One way to think about it, is that a user has to register, and their registered name is their "directory/homepage".

Links has been used as a business card type site, but I'm not sure it's been taken to the "community" or "home page" extreme yet.

Quote Reply
Re: Links as homepage-generator In reply to
I think almost the 70% of your needs should be implemented into the next release of LinkSQL. Be patient for a while! :-)

I did the same problem. Currently I use links as a multiuser document managing system. I heavily changed the code and I think it's almost impossible to give you in easy steps how to do the same (or something similar on your site).

You can have a look on my unstable dev release here:

http://marymode.com/c4sql/pages

right now I stopped to work on it because the new release should turn everything more simple.

but, just in case, here a briefing of all mods I did on it.

- external management of documents. They work sorta of attachments. This allow me to create future implementations concerning documents in a very easy way.

- Geografical (SIT) trick (normalizzation) that allow connection of documents in a geographycal visualizzation system.

- multiuser administration pannel. People can access the admin directory and do things dependig on their gerarchy.
I bypassed the Alex user system.

- Expirator system that deletes expired records and/or notify it via email to the Contact_name

- Events management system and calendar.

- Human date (12-Jan-2000 insead of 20000112) format avalidable everywhere.


I spent 4 month for all this stuff and I'm planning to put everything on-line 'stable' with the next LinsSQL release within the end of summer. During this period I'll post here some of the mods I'm implemening.

cheers

lepo


Lepo - lepo@comune.carpi.mo.it
Quote Reply
Re: Links as homepage-generator In reply to
Maybe its my bad english?!
I have done this mod with 1.11 in thoughts and the most part of it in a practise demo in my intranet.
Everything is possible and very easy to do. Only the one thing, how to set the trigger for "building details" to no is my problem no. Everything else is really easy and im very surprised about your answer.
Maybe i set the thing for demo online (but dont have a further license, thats the problem)

Hi Lepo, seems you are on the same way at mine; i have to rebuild an equal system, my target groups are customers, workers, sellers, industrie, media and others; industrie put in infos for customers, workers and sellers, sellers only for workers and customers and media for all.

I think my english is to bad to discuss this big project here; i have all new features write down but will wait like you for the next version.

Quote Reply
Re: Links as homepage-generator In reply to
Ok just another try:
I need a separate cgi or a function as the last one in build.cgi that goes tru all the link-entrees and set a field to no. Think that must be an easy thing for sql, isnt it?
Robert

Quote Reply
Re: Links as homepage-generator In reply to
Just use the SQL Monitor in the Admin area.

UPDATE Links set FieldName = 'No'

That will update _all_ the fields to 'No'

If you want to only update fields that are some how different, say for example, which are 'Null' and not 'Yes' then use something like:

UPDATE Links set FieldName = 'No' where FieldName=''





Quote Reply
Re: Links as homepage-generator In reply to
Yeah, Thanks, have got it, with PhpMyAdmin.
But do you know how i could do this with the script (sub or extern cgi) for itself; so i must not do after every build a call of the PhpMyAdmin; should be done on an easier way.
Robert
Have you got my idea now? You must think about another thing than i, cause itīs really easy to this with a litle logical of the detail.html.

Quote Reply
Re: Links as homepage-generator In reply to
You can just put a $db->do command into the nph-build.cgi file after you initialize a handle.

Look at the jump.cgi for the syntax for the do-> Update command, and just replace the SQL statement with the one I gave you above.

If you use the Where fieldname = '' you'll get a little better performance on large databases.



Quote Reply
Re: Links as homepage-generator In reply to
Have tested this night some sql-statements; now it builds only when Detailed=Yes and Build = YES; this afternoon i will try your advice. In germany its 6:14 at morning and time to go to bed :-( Think someone should program my inner perl not to need so much sleep :-)

Quote Reply
Re: Links as homepage-generator In reply to
YEAH! Have it running:

Insert in
sub build_all
after &build_category_pages();
Code:
&set_build_no();
Then insert the sub set_build_no at the end of the file before the 1;

Code:
sub set_build_no {
# --------------------------------------------------------------
# Wrap in a subroutine to prevent possible mod_perl probs.
#
my $in = new CGI;
my ($db);

# Create our database object.
$db = new Links::DBSQL $LINKS{admin_root_path} . "/defs/Links.def";
# Set all Build to Nein
$db->do ("UPDATE Links set Build = 'Nein' where Build='Ja'");
}
Cool; no there is nothing more to do than some simple logic in link.html to have a real cool homepage-generator.

By the way; what do think, it is possible to get from alex anonther license for free only to play around, binding mods and so here for the community? I do that here in my intranet with 10 or more copies, but so i cant show anyone what is possible with this lovely program.