Re: Need Photo Placement Suggestions

This WebDNA talk-list message is from

2002


It keeps the original formatting.
numero = 41021
interpreted = N
texte = >In working with an online newsletter and accompanying administration >interface... >I would like to provide a form for the administrator to submit the following >information for each article: > 1. Title > 2. Body > 3. Images >Let's say the administrator would be able to submit up to 3 image filenames >from his/her image library. > >Now for my pondering... >I would like to place the specified images throughout the body of the >article automatically (placement being determined by the length of the >newsletter article). I do not want to ask the administrator where to place >the images, only what order to place them (image1, image2, image3). > >I have thought about how to go about this and both [countchars] and/or >[countwords] come to mind, but that's about as far as I have gotten... I >can't figure out how to actually code this scenario. Has anyone else worked >with a similar project or does anyone have any other suggestions that may >help me make this happen? > >Kim Hi Kim,If you want to give people some control over where the images are placed, I like Anup's solution, it is simple and elegant. If you cannot do it his way, think about this:With 4 equally sized text blocks, you will need 3 images to separate them. Count the number of words in the entire volume of text, then divide it by 4 (using ceil() ) which will give you roughly the number of words in each of 4 sections of text, then set the results to a variable [numWords].Next, use listwords combined with [index]\[numWords] to determine where to place each of the 3 image tags in the text. This will place each tag in between two blocks of equally sized text, and it will not break any words apart. Sincerely, Kenneth Grome------------------------------------------------------------- Kenneth Grome & Associates US-Asian Business Specialists Philippine Business Office +63 (32) 255-6921 Primary Email Address owner@kengrome.com Alternate Email Address kengrome@webdna.net -------------------------------------------------------------------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://search.smithmicro.com/ Associated Messages, from the most recent to the oldest:

    
  1. Re: Need Photo Placement Suggestions (Kenneth Grome 2002)
  2. Re: Need Photo Placement Suggestions (Brian Fries 2002)
  3. Need Photo Placement Suggestions (Kimberly D Ingram 2002)
  4. Re: Need Photo Placement Suggestions (Anup Setty 2002)
>In working with an online newsletter and accompanying administration >interface... >I would like to provide a form for the administrator to submit the following >information for each article: > 1. Title > 2. Body > 3. Images >Let's say the administrator would be able to submit up to 3 image filenames >from his/her image library. > >Now for my pondering... >I would like to place the specified images throughout the body of the >article automatically (placement being determined by the length of the >newsletter article). I do not want to ask the administrator where to place >the images, only what order to place them (image1, image2, image3). > >I have thought about how to go about this and both [countchars] and/or >[countwords] come to mind, but that's about as far as I have gotten... I >can't figure out how to actually code this scenario. Has anyone else worked >with a similar project or does anyone have any other suggestions that may >help me make this happen? > >Kim Hi Kim,If you want to give people some control over where the images are placed, I like Anup's solution, it is simple and elegant. If you cannot do it his way, think about this:With 4 equally sized text blocks, you will need 3 images to separate them. Count the number of words in the entire volume of text, then divide it by 4 (using ceil() ) which will give you roughly the number of words in each of 4 sections of text, then set the results to a variable [numWords].Next, use listwords combined with [index]\[numWords] to determine where to place each of the 3 image tags in the text. This will place each tag in between two blocks of equally sized text, and it will not break any words apart. Sincerely, Kenneth Grome------------------------------------------------------------- Kenneth Grome & Associates US-Asian Business Specialists Philippine Business Office +63 (32) 255-6921 Primary Email Address owner@kengrome.com Alternate Email Address kengrome@webdna.net -------------------------------------------------------------------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://search.smithmicro.com/ Kenneth Grome

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

Ship via options price (2000) Partial credits (2002) Security Question (1997) [WebDNA] WebDNA 7 (2011) Help! WebCat2 bug (1997) b12 cannot limit records returned and more. (1997) WebCat2_Mac RETURNs in .db (1997) What file? (1997) Got WebCat buyer's remorse? (1998) OT. Self explanatory (2003) [isfolder] and [filename] (1997) searching withe db up three directories not working (1999) Alternating colors (1997) UPDATE PROBLEM (1997) REPLACE problem (2000) Custom WebCat Prefs ... (1997) Ampersand (1997) Not really WebCat- (1997) For those of you not on the WebCatalog Beta... (1997) Almost a there but..bye bye NetCloak (1997)