URL decode street addresses from PHP

Hi there,
I had a php programmer write me a script to download information from a local real estate board, and it works great, but we had to have it download to an xml file using urlencode in php (there were characters in the listings that caused problems - ie. > < & ").
Anyways, now I'm parsing the information in flash, and still left with a few "+" signs between street names (ie. Bear+Mountain Road).
I tried adding:
var loadVars:LoadVars = new LoadVars();
loadVars.decode(i.attributes.street);
trace(i.attributes.street);
in my actionscript, but I still end up with "Bear+Mountain Road."
I guess either the "decode" function doesn't work to remove "+" signs, or I'm using the wrong thing.
Any ideas?
Right now it seems to be ONLY "+" signs, so even if there is a way to search the attribute and remove them that would be great!

you can remove them using the flash string methods:
yourstring = yourstring.split("+").join(" ");

Similar Messages

  • Map a (street) address from the Web?

    I must be missing something. Is there no way (other than remembering it) to map an address you find on the web?
    On the desktop, the Google Toolbar does this nicely...one of the things Google got with Maps when they acquired it. Surely Steve could hit Eric up for one more bit of technology, no?
    Since there's no way to select text, much less a clipboard, these really need to be made into links by Safari.

    There are several ways.
    The easiest way: If you have your address book set up, tap on an address in your address book. This should bring up a map with a red pin.
    Click on the red pin and you get more options. Like you can make it a bookmark within Google Maps so it is easy to get driving directions to or from.
    Also, when in maps, you can type Address, State, Zip in the box at the top and it will bring up a map (which you can then bookmark, place in your address book, etc.)

  • Mac stolen, Find My Mac found it, get IP address from Apple?

    Five Macs were stolen from our non-profit Friday night. A few minutes ago Find My Mac found one a few miles away, with a pretty good street location (no proof of which house).  Apple obviously has the IP address of the location, but it's not in the Find My Mac report (perhaps to prevent vigilantism).  Unfortunately neither the police in the stolen location nor the potential recovery location are interested in doing research.
    Can Apple give (or be compelled to give) the IP address to the police, so the police can get the street address from the ISP (it's a residential area, so likely cable or DSL)?
    Anyone have experience with this?   Thanks.

    I just spoke with excellent Apple support (really, no sarcasm).  They obviously have the IP address of the Internet connection where the stolen Mac was booted (how else could Find My Mac report it?).  They gave me the phone number of Apple legal that the police need to call to get that IP address from Apple, so that the pertinent ISP can then supply the street address (or the cell ID if hot spot--yes, could be a throw-away) of the boot location of the stolen Mac.  The process can take a while, but the perp's (or the fence's) location or ID is the permanent record.
    I think the police need to be prodded, but they may say it's too low level.  Although they did say our office complex has been a target lately.

  • Why are url and email addresses not fully viewable in a PDF when generated from a Word file?

    I have a question?
    A colleague in our Copenhagen office wanted to generate a pdf from a Word file.  She is working on a Windows 2007 operating system and is running Acrobat Pro 9.  When she generated the PDF only part of a url and an email address was visible when the PDF was viewed.  She was wofking from Standard settings.  I am running the same software on the same Windows platform and using the same computer equipment with the same settings yet I was able to generate a PDF where the full url and email address was visible.
    Can anyone out in Adobe Acrobat land provide me with an answer?
    Patrick Lennon

    That's probably because the Mac people are opening or viewing the PDFs within the Mac's "Mail" program or with the "Preview" program and not with Acrobat.
    Since the Windows people aren't using these programs and most likely just Acrobat or Adobe Reader, the layers are kept hidden.
    I'm afraid the only way to truly keep those layers hidden is to delete them before saving your file as a PDF. (Of course, do a "Save As" and keep your original .ai file intact.

  • Where is URL stored in CRM tables How to retreive URL address from table

    Hi,
    Can any one tell where URL address is stored in CRM.
    And how to retreive URL Address from CRM tables.
    As i'm not able to find exactly how to retrive the url form the tables. as the URL address is not visible.
    Thanks & Regards,
    Rajender.
    Edited by: Rajender k on Aug 12, 2008 6:37 PM

    I am not able to get you. Please rephrase or elaborate.

  • Collect email addresses from html file or URL

    Hi guys, it sounds never been disccussed here,
    I have a HTML file which is huge , contains text graphics and email addresses, if I want to copy the email address manually, it will take long time,
    so have anybody thought of a JSP script to do this task ? , just to read the html or the URL and to collect all the email addresses there !

    Hi guys, it sounds never been disccussed here, Probably because most developers dont like to be
    spammed and dont like to make programs that can
    collect email addresses from a website or url?OWNED
    definitely owned.

  • How to Export full street address of the contacts from AD OU

    How to Export full street address of the contacts from AD OU

    Break down the one liner suggested by Chen . What do you see when you run the below :
    Get-ADUser -Searchbase 'OU=XYZ,DC=XYZ,DC=XYZ' -Filter * -Properties *
    You will have to replace the OU path in the above.
    Once you see the Users are an output of the above, try below :
    Get-ADUser -Searchbase 'OU=XYZ,DC=XYZ,DC=XYZ' -Filter * -Properties * |
    Select SamaccountName, @{n="Full Address";E={[String]::Join(';',$_.StreetAddress , $_.l, $_.PostalCode, $_.Country)}}
    If you are able to see the objects till this point then only you will get those in your CSV. These are nothing but basic steps to follow when someone gives you a solution.
    Hope this helps.
    Knowledge is Power{Shell}
    DexterPOSH
    My Blog

  • Street address not synching from Microsoft Outlook

    I just got a Blackberry Pearl and installed the desktop software and am trying to synch my contacts with Microsoft Outlook. Everything is working fine EXCEPT the street address field. Only the city, state and zip are showing up on my BB.
    Can anyone help? Thanks 

    Hi Erikcole7,
    To sync your corporate Exchange, you do need to work with yout IT group at your employer. However, I have included a link that provides you with a step-by-step process in getting this completed. 
    Though the device at this link is not the Droid X, I have verified that this device will work in the same way.
    http://www.motorola.com/staticfiles/Support/Experiences/Android_Support/_Images/Static_files/Microsoft-Exchange-Email.pdf
    Best regards, 

  • Cannot pass variables from PHP to actionscript 3.0

    I am using CS3 and I write the following code as to pass variable to flash from PHP
    Actionscript
    var myLoader:URLLoader = new URLLoader();
    myLoader.dataFormat = URLLoaderDataFormat.TEXT;
    var myRequest:URLRequest=new URLRequest("http://localhost/moodle/value.php");
    myLoader.load(myRequest);
    myLoader.addEventListener(Event.COMPLETE,onCompleteHandler);
    var myValue: String;
    function onCompleteHandler(e:Event):void{
              var myvariable: URLVariables = new URLVariables(e.target.data);
              myValue = myvariable.values;
                      trace(myValue);
    PHP file
    <?php
       echo ('values = 8');
    ?>
    But I always get the error and cannot get the values by using trace();
    Before i try to use "myLoader.dataFormat = URLLoaderDataFormat.VARIABLES;" I still get the same error.
    Error: Error #2101: The String passed to URLVariables.decode() must be a URL-encoded query string containing name/value pairs
              at Error$/throwError()
              at flash.net::URLVariables/decode()
              at flash.net::URLVariables$iinit()
              at flash.net::URLLoader/flash.net:URLLoader::onComplete()
    Can anyone help me?

    The error is fixed.The new version is like that
    Actionscript
    var myLoader:URLLoader = new URLLoader();
    myLoader.dataFormat = URLLoaderDataFormat.TEXT;
    var myRequest:URLRequest=new URLRequest("http://localhost/moodle/value.php");
    myLoader.load(myRequest);
    myLoader.addEventListener(Event.COMPLETE,onCompleteHandler);
    var myValue: String;
    function onCompleteHandler(e:Event):void{
              var myvariable: URLVariables = new URLVariables(e.target.data);
              myValue = myvariable.values;
                      trace(myValue);
    php file
    <?php
       echo "values=8";
    ?>
    The output finally is "null" in flash file. Why does it happen? It should give me 8 when I input trace(myValue);

  • Special characters in String variable sent from php.

    Hello. Assuming that I send some String variable from php into flash:
    AS3:
    var MyImportedString:String;
    var variables_page_text:URLVariables = new URLVariables();
    var varSend_page_text:URLRequest = new URLRequest("MyPHP.php");
    varSend_page_text.method = URLRequestMethod.POST;
    varSend_page_text.data = variables_page_text;
    var varLoader_page_text:URLLoader = new URLLoader;
    varLoader_page_text.dataFormat = URLLoaderDataFormat.VARIABLES;
    varLoader_page_text.addEventListener(Event.COMPLETE, var_comp_page_text);
    varLoader_page_text.load(varSend_page_text);
    function var_comp_page_text(event:Event):void {
        MyImportedString =  event.target.data.MyVariable;
    php:
    <?php
    header('Content-Type: text/html; charset=utf-8');
    $MyString = "some tekst &";
    print "MyVariable=" . $MyString;
    ?>
       I've noticed that the special character '&' residing inside String, throws an error:  #2101: The String passed to URLVariables.decode() must be a URL-encoded query string containing name/value pairs.
      My first thought was, it has something to do with html entities, but other entities (like <> or ") don't throw any error. Besides, the use of php functions like htmlentities(); or html_entity_decode(); doesn't make any difference in this case:
    print "MyVariable=" . htmlentities($MyString);
    or
    print "MyVariable=" . html_entity_decode($MyString);
      I've also noticed that characters like '%', '^', '+' don't show up at all;
      What does it mean? Any ideas?
      Reagards.

    Thank You 'moccamaximum'.
    Ok. So here is the solution (php function posted by 'moccamaximum' does the trick):
    AS3:
    var MyImportedString:String;
    var variables_page_text:URLVariables = new URLVariables();
    var varSend_page_text:URLRequest = new URLRequest("MyPHP.php");
    varSend_page_text.method = URLRequestMethod.POST;
    varSend_page_text.data = variables_page_text;
    var varLoader_page_text:URLLoader = new URLLoader;
    varLoader_page_text.dataFormat = URLLoaderDataFormat.VARIABLES;
    varLoader_page_text.addEventListener(Event.COMPLETE, var_comp_page_text);
    varLoader_page_text.load(varSend_page_text);
    function var_comp_page_text(event:Event):void {
        MyImportedString =  event.target.data.MyVariable;
         trace(MyImportedString);        // Output:  some text &%^+
    php:
    <?php
    header('Content-Type: text/html; charset=utf-8');
    $MyString = "some text &%^+";
    print "MyVariable=" . flash_encode($MyString);
    function flash_encode($string){
         $string = rawurlencode(utf8_encode($string));
         $string = str_replace("%C2%96", "-", $string);
         $string = str_replace("%C2%91", "%27", $string);
         $string = str_replace("%C2%92", "%27", $string);
         $string = str_replace("%C2%82", "%27", $string);
         $string = str_replace("%C2%93", "%22", $string);
         $string = str_replace("%C2%94", "%22", $string);
         $string = str_replace("%C2%84", "%22", $string);
         $string = str_replace("%C2%8B", "%C2%AB", $string);
         $string = str_replace("%C2%9B", "%C2%BB", $string);
         return $string;
    ?>

  • Problem with Contribute URL decoding a javascript

    Hi,
    On all pages of our website we have a Google Analytics script:
    <script type="text/javascript">
         var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl" : "http://www");
         document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
    </script>
    But every time someone makes a change to one of the pages with Contribute, the script is automatically altered to this:
    <script type="text/javascript">
         var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl" : "http://www");
         document.write(unescape("<script src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'></script>"));
    </script>
    The difference is that Contribute has decided to automatically URL decode the first of the two closing </script> tags, which breaks the script; it's URL encoded for a reason: so that the browser doesn't end the script prematurely on parsing the first of the </script> tags. Is there some setting within Contribute that will allow us to stop this from happening? We just want Contribute to leave the Javascript alone.
    Many thanks,
    Mark

    I was able to solve this by including the google code in an external PHP file as well. However if my template has a repeating region in it, and my contribute user adds a region from it, it breaks the code again :/
    Are there any other suggestions out there??

  • How to populate DataGird with data returned from php page?

    Hi, I'm new in Flex, I try to populate DataGrid with data from PHP, My code is
    <mx:HTTPService 
    id="personRequest" result="getPerson(event)" url=http://localhost/searchPerson.php useProxy="false" method="POST" showBusyCursor="true" resultFormat="e4x">
    </ mx:HTTPService>
    <mx:DataGrid 
    id="searchResult" dataProvider="{???what to paste here???}" y="30">
    </mx:DataGrid>
    private  
    function getPerson(evt:ResultEvent):void { var res:XMLList = evt.result..dane as XMLList;searchResults =
    new XMLListCollection(res); 
    output from PHP
    <person>
    <dane>
    <name>ABC</name>
    <street>XLXXLX</street>
    </dane>
    <dane>
    <name>DEF</name>
    <street>YAYAYAY</street>
    </dane>
    </person>
    If I set the dataProvider as "searchResults" it doesn't work. I probably have to set as dataprovider any ArrayCollection , but I don't know how to convert my XMLListCollection to it.
    Could anyone help me populate Datagrid with
    name | streer
    ABC, XLXXLX
    DEF, YAYAYAY
    Best Regards,
    Mariusz

    Thanks for your reply, but I'm afraid it doesn't work :-( Could you browse my code and check what I'm doing wrong???
    full mxml code:
    <?xml version="1.0" encoding="utf-8"?><mx:Application 
    xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" applicationComplete="personRequest.send()">
    <mx:Script><![CDATA[
         import mx.rpc.events.ResultEvent; 
         [Bindable]
         public var searchResultsXML:XML;  
         private  function getPerson(evt:ResultEvent):void 
          {          searchResultsXML = (evt.result
    as XML);
              trace(searchResultsXML);     }
    ]]></mx:Script>  
    <mx:HTTPService 
    id="personRequest" result="getPerson(event)" url=http://localhost/searchPerson.php useProxy="false"
    method="POST" showBusyCursor="true" resultFormat="e4x"></mx:HTTPService>
    <mx:DataGrid  id="searchResult" dataProvider="{searchResultsXML.dane}"></mx:DataGrid>
     </mx:Application> 
    trace statement returns:
    <person>
    <dane>
    <id>1</id>
    <nazwisko>Topczewski</nazwisko>
    <imie>Mariusz</imie>
    <imie2/>
    <miejscowosc>Bia?ystok</miejscowosc>
    <ulica>Nowogródzka</ulica>
    <dom>7B</dom>
    <lokal>25</lokal>
    </dane>
    <dane>
    <id>1</id>
    <nazwisko>Topczewski</nazwisko>
    <imie>Mariusz</imie>
    <imie2/>
    <miejscowosc>Bia?ystok</miejscowosc>
    <ulica>Sybiraków</ulica>
    <dom>15</dom>
    <lokal>27</lokal>
    </dane>
    </person>

  • How to get customer and vendor street addresses 4 and 5?

    I need to know what table/field has the customer and vendor street addresses 4 and 5 stored in to them and how to access these fields.
    This is for mapping on a LSMW customer and vendor data conversion.
    Thanks!
    Scortt

    Thread should be moved to
    Such fields do belong to address management tables. eg:ADRC-NAME3, ADRC-NAME4...
    In other words they do not belong to customer master data so they are not reachable directly from customer master data fields.
    The link is KNA1-ADRNR = ADRC-ADDRNUMBER
    You might face difficulties in the mapping except if you plan to process in LSMW both DEBMAS idocs AND ADRMAS idocs
    Alain

  • How can I get the address from a map struct?

    Hello,
    Who knows how to get the address from a map struct, and what's the meaning of the eighth argument (addr) of ufs_getpage() ?
    I developed a modular to encrypt certain files. The approach is: I�fll change the vnode's v_op pointer when opening a file which should be decoded. I make the vnode->v_op point to my own ops struct. I made a new ufs_getpage function like below:
    static int newufs_getpage(struct vnode* vp, offset_t off, size_t len,
    uint_t* protp, page_t* plarr[], size_t plsz,
    struct seg* seg, caddr_t addr, enum seg_rw rw,
    struct cred* cr)
    call old ufs_getpage(vp, off, len, protp, plarr, plsz, seg, addr, rw, cr);
    decode the page.
    After reading some source code about kernel, I know the plarr is the page which is read from the disk. But I don't know how to get the address of the page. I tried like below, but failed.
    caddr_t baseaddr;
    page_t *pp;
    pp = plarr[0];
    �c�c
    baseaddr = hat_kpm_page2va(pp, 0);
    �c�c
    I logged the baseaddr:
    cmn_err(CE_NOTE, �gbaseaddr %s�h, baseaddr);
    or
    char _buff[8];
    int _len;
    copyinstr(baseaddr, buff, 8, &len);
    cmn_err(CE_NOTE, �gbaseaddr %s�h, _buff);
    But I found the baseaddr is not what I want. Is there something wrong with my approach? What's the meaning of the eighth argument (addr) of ufs_getpage()
    By the way, is there any documents concerning to the functions such as segvn_fault�Appmapin/ppmapout except the source code?

    Hiya,
    I think the address is the faulting address in segmap.
    But why not have a look at the file event management framework in NFSv4:
    http://cvs.opensolaris.org/source/xref/on/usr/src/uts/common/fs/fem.c
    To support NFSv4 delegation, FEM provides hooks to intercept filesystem operations.
    Maybe you could use that to implement what you want? Probably safer than doing what you are doing now. Go see fem_install().
    Cheers,
    R.
    Message was edited by:
    ralphyt

  • DON'T HAVE A HELP TAB IN MY MENU BUTTON. CANT EVEN COPY A URL IN MY ADDRESS BAR OR REFRESH IT ?

    how on earth can you help people when all you do is direct them to another page to click on something that doesn't help. this new version is awful . i cannot even put a url address in my address bar, nor can i refresh the address bar as it won't highlight at all. i keep going to all sorts of help pages and they are no help at all. i have used firefox for years and never had so much trouble with anything. the worse thing is your support and not being able to talk to any about anything. as it is i have to go all over just to find maybe an answer to this.i am using a background theme that i used before the new updated version and had no problems with it. if your themes are not compatible then why have them ??? the address bar problem is not present if i get rid of the theme and use the plain boring theme that you have . all i want to know is why this issue is happening with the theme i am using. and if possible it would be nice to get an answer in my email so i don't have to click on a dozen help pages trying to find it . thank you ..
    <sub>edit by a moderator: if you want to be able to discuss the issue with someone, don't do it in a shouting format (all uppercase), as this is considered rude on the internet - therefore i have converted your text into normal characters. in addition i have removed your address from public display since you will be notified per mail once somebody replies to the thread anyway. (philipp)</sub>

    '''What is your support question?''' This? <br />CANT EVEN COPY A URL IN MY ADDRESS BAR OR REFRESH IT ?
    A number of other users have mentioned a similar problem. <br />
    Chances are that you have an add-on installed that isn't completely compatible with Firefox 29. '''You''' need to figure out the culprit and disable it until an update for that add-on is available.
    If so, '''Try Firefox Safe Mode''' to see if the problem goes away. [[Troubleshoot Firefox issues using Safe Mode|Firefox Safe Mode]] is a troubleshooting mode that turns off some settings, disables most add-ons (extensions and themes).
    If Firefox is open, you can restart in Firefox Safe Mode from the Help menu:
    *In Firefox 29.0 and above, click the menu button [[Image:New Fx Menu]], click Help [[Image:Help-29]] and select ''Restart with Add-ons Disabled''.
    *In previous Firefox versions, click on the Firefox button at the top left of the Firefox window and click on ''Help'' (or click on ''Help'' in the Menu bar, if you don't have a Firefox button) then click on ''Restart with Add-ons Disabled''.
    If Firefox is not running, you can start Firefox in Safe Mode as follows:
    * On Windows: Hold the '''Shift''' key when you open the Firefox desktop or Start menu shortcut.
    * On Mac: Hold the '''option''' key while starting Firefox.
    * On Linux: Quit Firefox, go to your Terminal and run ''firefox -safe-mode'' <br>(you may need to specify the Firefox installation path e.g. /usr/lib/firefox)
    When the Firefox Safe Mode window appears, select "Start in Safe Mode".<br>
    [[Image:Safe Mode Fx 15 - Win]]
    '''''If the issue is not present in Firefox Safe Mode''''', your problem is probably caused by an extension, and you need to figure out which one. Please follow the [[Troubleshoot extensions, themes and hardware acceleration issues to solve common Firefox problems]] article to find the cause.
    ''To exit Firefox Safe Mode, just close Firefox and wait a few seconds before opening Firefox for normal use again.''

Maybe you are looking for

  • Issue with process order confirmation

    Hi,   I m doing the testing of SAP EHP4 To EHP6 up-gradation. I tried to confirm process order XXXXXX with T-code COR6N. In this process order there 2 phase for 2 activity. Now when I entered the order in COR6N I click on enter its automatically take

  • How to prepare  for interview

    hi everyone, Just know completed my sap sd course. i would like to know how prepare my self for interview..... i do have Configuration  skills in u2022     Sales Process: Expert in Quotation, Sales Order, Delivery, and Billing. u2022     Special Busi

  • Scanned documents do not print out correctly on forms.

    I scanned a pdf file to my computer.  I opened the pdf file on my computer using Adobe Reader.  I printed the file using my printer.  The pdf file did not print out correctly.  The printed text was out of alignment with the form I was printing on.  T

  • Cisco Prime 1.3 applications dashboard not visible

    Dear all, I have added a flow exporter from 2 wlc 5508 in direction of our Cisco Prime, under system / data sources i see data from my controllers coming but status is down. Addtionally I cannot see under details dashboards the applications dashboard

  • Facebook won't download on droid eris replacement phone

    I just received a replacement phone yesterday for my Droid Eris.  As I was getting things set-up, I tried to install/update the Facebook app.  It goes through the whole process and then says Installation Unsuccessful.  So when I click on that, it say