Hi Jos:

         Thanks for the reply.

At 05:44 PM 8/14/01 +0100, [EMAIL PROTECTED] wrote:
>I must agree with Jos on this ... I read the email and I saw that what Ron was
>asking for was soft reference ... like I mentioned before a lot of the
>situations (like I mentioned my experience) .. where you think that soft
>reference is the only way to do it is because your mindset had been stuck in
>that way but solutions using other data structures will do the job and
>everyone can understand it much better ... plus you get to keep strict which i
>never do without ... the use strict and #!perl lines have been programmed into
>my fingers already ...
>
>i had a situation once when one of my colleague was trying to get round a
>problem and he asked me how to do soft reference ... when i asked him why he
>explained what he was trying to do and suddenly we both realised that all he
>needed was a hash!!  Look through the problem to make sure soft reference is
>what you want 'cos liek Jos said it is considered bad programming practice.

         Ok here's my original problem. I have 166 HTML tag pages that I'm 
processing one at a time. Each tag page can have 197 attributes and 
potentially more arguments. Once I process the tag section of the page, I 
have to address the attributes and arguments. The problem is that any given 
tag page can have none or 197 attributes or anywhere in between. I needed a 
method whereby I could create variables "on the fly." What I ended up doing 
was taking the attribute name and appending it to an array. I then use the 
name to create a series of $attxxx{$attname} where "xxx" is a unique handle 
for a specific value that may or may not exist for that attribute. The name 
of the variable must come from the text on the page. Once I've gathered all 
of the attribute names into an array, I sort the array and begin processing 
the page. How can this be done while not using soft references?

         Do I make sense?

         Ron Woodall


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to