Jim Reverend (revjim) wrote in lj_dev,
Jim Reverend
revjim
lj_dev

Problem with percent codes

Update: This has been solved and is only left here for historical purposes.

If I enter the following as entrydata for post:

"test[percentsign]20test[precentsign]20test"

The post actually shows up as:

"test test test"


Though this is recommended conversion when handling URLs, I believe a [percentsign]20 should be left as just that.

The above "%" symbols have been replaced with "[percentsign]" in order to make sure they are not improperly converted... for your viewing pleasure, the following line has been typed with the "%" actually in place. You will see that it has been replaced by spaces.

test test test

In this instance, it makes no REAL difference, as the and " " look the same when rendered in HTML....

however... when attempting to make a A tag with an HREF to a URL that contains a space... this causes problems. If a URL contains a space, that space must be encoded as [percentsign]20.... however, LiveJournal seems to be replacing that encoding with the " " character, and therefore, generating an improper HREF attribute on the A tag.

A%0
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 13 comments