Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
0

Can this be formatted?

LEGEND ,
Aug 23, 2007 Aug 23, 2007

Copy link to clipboard

Copied

I have a column in my SQL Server DB that stores the full address of a
customer. This is stored as a formatted string eg. 'The Croft, 22 Liddle
Lane, LittleTown, Big City, BB5 2AA'.

The problem is that I now need this to display in the HTML as a
conventionally formatted address with carriage returns after every comma,
straight from the recordset ie:

The Croft,
22 Liddle Lane,
LittleTown,
etc.

Is this possible?


TOPICS
Server side applications

Views

468
Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Aug 23, 2007 Aug 23, 2007

Copy link to clipboard

Copied

could you not use pattern matching or a regular expression in the serverside language you are using?

Votes

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Aug 23, 2007 Aug 23, 2007

Copy link to clipboard

Copied

Sure. Just use strstr() to replace all commas with ",<br>".

--
Murray --- ICQ 71997575
Adobe Community Expert
(If you *MUST* email me, don't LAUGH when you do so!)
==================
http://www.dreamweavermx-templates.com - Template Triage!
http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
http://www.dwfaq.com - DW FAQs, Tutorials & Resources
http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
==================


"orange22" <webforumsuser@macromedia.com> wrote in message
news:fajur8$r0n$1@forums.macromedia.com...
> could you not use pattern matching or a regular expression in the
> serverside language you are using?


Votes

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Aug 23, 2007 Aug 23, 2007

Copy link to clipboard

Copied

Oops - only if PHP, of course.

--
Murray --- ICQ 71997575
Adobe Community Expert
(If you *MUST* email me, don't LAUGH when you do so!)
==================
http://www.dreamweavermx-templates.com - Template Triage!
http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
http://www.dwfaq.com - DW FAQs, Tutorials & Resources
http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
==================


"Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
news:fajvvp$s9n$1@forums.macromedia.com...
> Sure. Just use strstr() to replace all commas with ",<br>".
>
> --
> Murray --- ICQ 71997575
> Adobe Community Expert
> (If you *MUST* email me, don't LAUGH when you do so!)
> ==================
> http://www.dreamweavermx-templates.com - Template Triage!
> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
> http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
> ==================
>
>
> "orange22" <webforumsuser@macromedia.com> wrote in message
> news:fajur8$r0n$1@forums.macromedia.com...
>> could you not use pattern matching or a regular expression in the
>> serverside language you are using?
>
>


Votes

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Aug 23, 2007 Aug 23, 2007

Copy link to clipboard

Copied

No, this is ASP.........

"Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
news:fak00e$sa3$1@forums.macromedia.com...
> Oops - only if PHP, of course.
>
> --
> Murray --- ICQ 71997575
> Adobe Community Expert
> (If you *MUST* email me, don't LAUGH when you do so!)
> ==================
> http://www.dreamweavermx-templates.com - Template Triage!
> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
> http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
> ==================
>
>
> "Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
> news:fajvvp$s9n$1@forums.macromedia.com...
>> Sure. Just use strstr() to replace all commas with ",<br>".
>>
>> --
>> Murray --- ICQ 71997575
>> Adobe Community Expert
>> (If you *MUST* email me, don't LAUGH when you do so!)
>> ==================
>> http://www.dreamweavermx-templates.com - Template Triage!
>> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
>> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
>> http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
>> ==================
>>
>>
>> "orange22" <webforumsuser@macromedia.com> wrote in message
>> news:fajur8$r0n$1@forums.macromedia.com...
>>> could you not use pattern matching or a regular expression in the
>>> serverside language you are using?
>>
>>
>
>


Votes

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Aug 23, 2007 Aug 23, 2007

Copy link to clipboard

Copied

You could do the same in VBScript, using the replace() function.

--
Murray --- ICQ 71997575
Adobe Community Expert
(If you *MUST* email me, don't LAUGH when you do so!)
==================
http://www.dreamweavermx-templates.com - Template Triage!
http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
http://www.dwfaq.com - DW FAQs, Tutorials & Resources
http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
==================


"Ian Hughes" <ihughes@nospam.net> wrote in message
news:fak0qn$t5j$1@forums.macromedia.com...
> No, this is ASP.........
>
> "Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
> news:fak00e$sa3$1@forums.macromedia.com...
>> Oops - only if PHP, of course.
>>
>> --
>> Murray --- ICQ 71997575
>> Adobe Community Expert
>> (If you *MUST* email me, don't LAUGH when you do so!)
>> ==================
>> http://www.dreamweavermx-templates.com - Template Triage!
>> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
>> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
>> http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
>> ==================
>>
>>
>> "Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
>> news:fajvvp$s9n$1@forums.macromedia.com...
>>> Sure. Just use strstr() to replace all commas with ",<br>".
>>>
>>> --
>>> Murray --- ICQ 71997575
>>> Adobe Community Expert
>>> (If you *MUST* email me, don't LAUGH when you do so!)
>>> ==================
>>> http://www.dreamweavermx-templates.com - Template Triage!
>>> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
>>> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
>>> http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
>>> ==================
>>>
>>>
>>> "orange22" <webforumsuser@macromedia.com> wrote in message
>>> news:fajur8$r0n$1@forums.macromedia.com...
>>>> could you not use pattern matching or a regular expression in the
>>>> serverside language you are using?
>>>
>>>
>>
>>
>
>


Votes

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Aug 23, 2007 Aug 23, 2007

Copy link to clipboard

Copied

How would I do this with a recordset item? Can you give me a brief example
please?

Thanks.


"Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
news:fak17l$d6$1@forums.macromedia.com...
> You could do the same in VBScript, using the replace() function.
>
> --
> Murray --- ICQ 71997575
> Adobe Community Expert
> (If you *MUST* email me, don't LAUGH when you do so!)
> ==================
> http://www.dreamweavermx-templates.com - Template Triage!
> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
> http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
> ==================
>
>
> "Ian Hughes" <ihughes@nospam.net> wrote in message
> news:fak0qn$t5j$1@forums.macromedia.com...
>> No, this is ASP.........
>>
>> "Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
>> news:fak00e$sa3$1@forums.macromedia.com...
>>> Oops - only if PHP, of course.
>>>
>>> --
>>> Murray --- ICQ 71997575
>>> Adobe Community Expert
>>> (If you *MUST* email me, don't LAUGH when you do so!)
>>> ==================
>>> http://www.dreamweavermx-templates.com - Template Triage!
>>> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
>>> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
>>> http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
>>> ==================
>>>
>>>
>>> "Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
>>> news:fajvvp$s9n$1@forums.macromedia.com...
>>>> Sure. Just use strstr() to replace all commas with ",<br>".
>>>>
>>>> --
>>>> Murray --- ICQ 71997575
>>>> Adobe Community Expert
>>>> (If you *MUST* email me, don't LAUGH when you do so!)
>>>> ==================
>>>> http://www.dreamweavermx-templates.com - Template Triage!
>>>> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
>>>> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
>>>> http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
>>>> ==================
>>>>
>>>>
>>>> "orange22" <webforumsuser@macromedia.com> wrote in message
>>>> news:fajur8$r0n$1@forums.macromedia.com...
>>>>> could you not use pattern matching or a regular expression in the
>>>>> serverside language you are using?
>>>>
>>>>
>>>
>>>
>>
>>
>
>


Votes

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Aug 23, 2007 Aug 23, 2007

Copy link to clipboard

Copied

variablename={recordsetvalue}
variablenameNew=replace(variablename, ',', ',<br>')

variablenameNew will contain the reformatted string.

--
Murray --- ICQ 71997575
Adobe Community Expert
(If you *MUST* email me, don't LAUGH when you do so!)
==================
http://www.dreamweavermx-templates.com - Template Triage!
http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
http://www.dwfaq.com - DW FAQs, Tutorials & Resources
http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
==================


"Ian Hughes" <ihughes@nospam.net> wrote in message
news:fak5n0$5ka$1@forums.macromedia.com...
> How would I do this with a recordset item? Can you give me a brief example
> please?
>
> Thanks.
>
>
> "Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
> news:fak17l$d6$1@forums.macromedia.com...
>> You could do the same in VBScript, using the replace() function.
>>
>> --
>> Murray --- ICQ 71997575
>> Adobe Community Expert
>> (If you *MUST* email me, don't LAUGH when you do so!)
>> ==================
>> http://www.dreamweavermx-templates.com - Template Triage!
>> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
>> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
>> http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
>> ==================
>>
>>
>> "Ian Hughes" <ihughes@nospam.net> wrote in message
>> news:fak0qn$t5j$1@forums.macromedia.com...
>>> No, this is ASP.........
>>>
>>> "Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
>>> news:fak00e$sa3$1@forums.macromedia.com...
>>>> Oops - only if PHP, of course.
>>>>
>>>> --
>>>> Murray --- ICQ 71997575
>>>> Adobe Community Expert
>>>> (If you *MUST* email me, don't LAUGH when you do so!)
>>>> ==================
>>>> http://www.dreamweavermx-templates.com - Template Triage!
>>>> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
>>>> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
>>>> http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
>>>> ==================
>>>>
>>>>
>>>> "Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
>>>> news:fajvvp$s9n$1@forums.macromedia.com...
>>>>> Sure. Just use strstr() to replace all commas with ",<br>".
>>>>>
>>>>> --
>>>>> Murray --- ICQ 71997575
>>>>> Adobe Community Expert
>>>>> (If you *MUST* email me, don't LAUGH when you do so!)
>>>>> ==================
>>>>> http://www.dreamweavermx-templates.com - Template Triage!
>>>>> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
>>>>> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
>>>>> http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
>>>>> ==================
>>>>>
>>>>>
>>>>> "orange22" <webforumsuser@macromedia.com> wrote in message
>>>>> news:fajur8$r0n$1@forums.macromedia.com...
>>>>>> could you not use pattern matching or a regular expression in the
>>>>>> serverside language you are using?
>>>>>
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>
>


Votes

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Aug 24, 2007 Aug 24, 2007

Copy link to clipboard

Copied

LATEST
Thanks.


"Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
news:fakdeu$eqc$1@forums.macromedia.com...
> variablename={recordsetvalue}
> variablenameNew=replace(variablename, ',', ',<br>')
>
> variablenameNew will contain the reformatted string.
>
> --
> Murray --- ICQ 71997575
> Adobe Community Expert
> (If you *MUST* email me, don't LAUGH when you do so!)
> ==================
> http://www.dreamweavermx-templates.com - Template Triage!
> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
> http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
> ==================
>
>
> "Ian Hughes" <ihughes@nospam.net> wrote in message
> news:fak5n0$5ka$1@forums.macromedia.com...
>> How would I do this with a recordset item? Can you give me a brief
>> example please?
>>
>> Thanks.
>>
>>
>> "Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
>> news:fak17l$d6$1@forums.macromedia.com...
>>> You could do the same in VBScript, using the replace() function.
>>>
>>> --
>>> Murray --- ICQ 71997575
>>> Adobe Community Expert
>>> (If you *MUST* email me, don't LAUGH when you do so!)
>>> ==================
>>> http://www.dreamweavermx-templates.com - Template Triage!
>>> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
>>> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
>>> http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
>>> ==================
>>>
>>>
>>> "Ian Hughes" <ihughes@nospam.net> wrote in message
>>> news:fak0qn$t5j$1@forums.macromedia.com...
>>>> No, this is ASP.........
>>>>
>>>> "Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
>>>> news:fak00e$sa3$1@forums.macromedia.com...
>>>>> Oops - only if PHP, of course.
>>>>>
>>>>> --
>>>>> Murray --- ICQ 71997575
>>>>> Adobe Community Expert
>>>>> (If you *MUST* email me, don't LAUGH when you do so!)
>>>>> ==================
>>>>> http://www.dreamweavermx-templates.com - Template Triage!
>>>>> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
>>>>> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
>>>>> http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
>>>>> ==================
>>>>>
>>>>>
>>>>> "Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
>>>>> news:fajvvp$s9n$1@forums.macromedia.com...
>>>>>> Sure. Just use strstr() to replace all commas with ",<br>".
>>>>>>
>>>>>> --
>>>>>> Murray --- ICQ 71997575
>>>>>> Adobe Community Expert
>>>>>> (If you *MUST* email me, don't LAUGH when you do so!)
>>>>>> ==================
>>>>>> http://www.dreamweavermx-templates.com - Template Triage!
>>>>>> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
>>>>>> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
>>>>>> http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
>>>>>> ==================
>>>>>>
>>>>>>
>>>>>> "orange22" <webforumsuser@macromedia.com> wrote in message
>>>>>> news:fajur8$r0n$1@forums.macromedia.com...
>>>>>>> could you not use pattern matching or a regular expression in the
>>>>>>> serverside language you are using?
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>
>


Votes

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines