List Info

Thread: Re: Substitute a single-quote syntax




Re: Substitute a single-quote syntax
user name
2007-02-02 04:50:15
--- In perl-beginner@yahoogroups.com, merlyn...
wrote:
>
> >>>>> "hooyar66" == hooyar66 
<pcbcad...> writes:
> 
> hooyar66> Any ideas?
> 
> About what?  Looks like you solved it.
> 
> -- 
> Randal L. Schwartz - Stonehenge Consulting Services,
Inc. - +1 503 
777 0095
> <merlyn...> <URL:http://www.ston
ehenge.com/merlyn/>
> Perl/Unix/security consulting, Technical writing,
Comedy, etc. etc.
> See PerlTraining.Stonehenge.com for onsite and
open-enrollment Perl 
training!
>

Hi Randal

No still not solved it.

The code below although it 'looks' correct is not being
interpreted 
correctly:

###########
#! perl 
use strict;
use warnings;
use diagnostics;

my $text = 'A ver~sion, of 5 6  NJH's SD card 'which' 
enab'#~%les the PCB itself to be plug'ged (directly)
into
a 
#,standard SD card input connector';

$text =~ s/'/\'/g;

print "$text:n$textnn";

print 'The previous single-quote should be a opener not a
closing 
quote';

###########

The second single-quote in my substitution line is not being
escaped 
causing all subsequent code - until the next single-quote -
to be 
treated as a sting.

They say 'a picture is worth a thousand words', the link
below will 
show a screenshot of my text-editor which uses Perl syntax
colour 
coding.

http://tinyurl.com/yrja7g

Thanks
NJH



Unsubscribing info is here: h
ttp://help.yahoo.com/help/us/groups/groups-32.html 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://g
roups.yahoo.com/group/perl-beginner/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http
://groups.yahoo.com/group/perl-beginner/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:perl-beginner-digest@yahoogroups.com 
    mailto:perl-beginner-fullfeatured@yahoogroups.com

<*> To unsubscribe from this group, send an email to:
    perl-beginner-unsubscribe@yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.c
om/info/terms/
 

Re: Re: Substitute a single-quote syntax
user name
2007-02-02 07:58:41
On Feb 2, 2007, at 5:50 AM, hooyar66 wrote:
> --- In perl-beginner@yahoogroups.com, merlyn...
wrote:
>>>>>>> "hooyar66" ==
hooyar66  <pcbcad...> writes:
>>
>> hooyar66> Any ideas?
>>
>> About what?  Looks like you solved it.
>>
>> --  
>> Randal L. Schwartz - Stonehenge Consulting
Services, Inc. - +1 503  
>> 777 0095
>> <merlyn...> <URL:http://www.ston
ehenge.com/merlyn/>
>> Perl/Unix/security consulting, Technical writing,
Comedy, etc. etc.
>> See PerlTraining.Stonehenge.com for onsite and
open-enrollment  
>> Perl training!
>>
>
> Hi Randal
>
> No still not solved it.
>
> The code below although it 'looks' correct is not being
interpreted
> correctly:
>
> ###########
>
> The second single-quote in my substitution line is not
being escaped
> causing all subsequent code - until the next
single-quote - to be
> treated as a sting.
>
> They say 'a picture is worth a thousand words', the
link below will
> show a screenshot of my text-editor which uses Perl
syntax colour
> coding.
>
> http://tinyurl.com/yrja7g
>
> Thanks
> NJH

Your problem is in thinking that this is a Perl issue.  It's
just  
your editor.  Mine handles this code just fine:
	http:/
/agileconsultingllc.com/single_quote.png

-Rob

Rob Biedenharn		http://agileconsultingl
lc.com
RobAgileConsultingLLC.com





Unsubscribing info is here: h
ttp://help.yahoo.com/help/us/groups/groups-32.html 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://g
roups.yahoo.com/group/perl-beginner/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http
://groups.yahoo.com/group/perl-beginner/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:perl-beginner-digest@yahoogroups.com 
    mailto:perl-beginner-fullfeatured@yahoogroups.com

<*> To unsubscribe from this group, send an email to:
    perl-beginner-unsubscribe@yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.c
om/info/terms/
 

[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )