Displaying User IP

I am unable to show the User IP , php file is working fine
Followed this article  : http://active.tutsplus.com/tutorials/actionscript/get-user-ip-address-using-php-and-action script-3/
My html : http://awaisahmad.info/uploads/user_ip.html
myphp : http://awaisahmad.info/uploads/ipfile.php
http://awaisahmad.info/uploads/Main.as
FLASH file
package
    import flash.display.Sprite;
    import flash.net.URLLoader;
    import flash.net.URLRequest;
    import flash.events.Event;
    import flash.events.MouseEvent;
    import fl.transitions.Tween;
    import fl.transitions.easing.Strong;
    public class Main extends Sprite
        var urlLoader:URLLoader = new URLLoader();
        var tween:Tween;
        public function Main():void
            getButton.addEventListener(MouseEvent.MOUSE_UP, getIP);
        private function getIP(e:MouseEvent):void
            urlLoader.load(new URLRequest("http://awaisahmad.info/uploads/ipfile.php"));
            urlLoader.addEventListener(Event.COMPLETE, showIP);
            tween = new Tween(getButton, "y", Strong.easeOut, getButton.y, 340, 1, true);
        private function showIP(e:Event):void
            ipField.text = e.target.data;
            ipFieldPressed.text = e.target.data;
PHP
$ip = $_SERVER['REMOTE_ADDR'];
echo $ip;

I am calling at  as3
urlLoader.load(new URLRequest("http://awaisahmad.info/uploads/ipfile.php"));
how should I solve this issue ?

Similar Messages

  • How to display user profile information in master page header

    I am trying to display user profile info like following in custom master page.
    I have just added a html code for displaying this info.
    Now, please tell me how could i achieve this
    I am doing this in sharepoint 2013 on-premise.

    see below is example for javascript and userprofile information
    <script type="text/javascript">//<![CDATA[
    $(document).ready(function
    var currentUser;
    // Ensure that the SP.js is loaded
    if (SP.ClientContext
    != null)
    SP.SOD.executeOrDelayUntilScriptLoaded(getCurrentUser,
    'SP.js');
    else
    SP.SOD.executeFunc('sp.js',
    null, getCurrentUser);
    function getCurrentUser()
    var context = new SP.ClientContext.get_current();
    var web = context.get_web();
    currentUser = web.get_currentUser();
    context.load(currentUser);
    context.executeQueryAsync(onSuccessMethod, onRequestFail);
    function onSuccessMethod(sender, args)
    var account = currentUser.get_title();
    var currentUserAccount = account.substring(account.indexOf("|")
    + 1);
    var currentUserAccountUnderScore = currentUserAccount.toLowerCase().replace(/\s/g,
    //alert(currentUserAccount);
    $("#username").text(currentUserAccount);
    $("#ProfileImage").attr("src",
    "https://mydomain-my.sharepoint.com/User%20Photos/Profile%20Pictures/"
    + currentUserAccountUnderScore +
    "_mydomain_onmicrosoft_com_MThumb.jpg");
    $("#ProfileImage").attr("alt", currentUserAccount
    + " User Profile Image");
    $("#ProfileImage").attr("class",
    "ss-profile-image");
    //This function runs if the executeQueryAsync call fails.
    function onRequestFail(sender, args)
    alert('request failed' + args.get_message()
    + '\n' + args.get_stackTrace());
    $("#ProfileImage").attr("src",
    "https://mydomain.sharepoint.com/SiteAssets/userImageDefault.jpg");
    //]]>
    </script>
    -Nilesh

  • I am loging in SAP. Initial screen come where it display User Menu and Sap

    Dear All,
    When i am loging in SAP. Initial screen come where it display User Menu and Sap Menu, but User menu is in active not showing but T code are executing then what object i have missed.
    can u help me?
    Thanks,
    Regards,
    Sachin

    Hi Sachin,
    It doesn't care if you're using SAP_ALL or any of those profile. That is not relevant. I had that case a few days ago, I'm not using any of those profiles and I made it work with help of one post.
    If you put the transactions in the tab "Menu" of the role in the PFCG, and if you activate parameters I mentioned in a prior post, then you should see the Menu.
    Tables SSM_CUST and USERS_SSM. The first is global and the other is user-especific.
    The link in one of the first post of this thread hace all the info.
    That should work, that worked in my case.
    What values the parameters have on those tables? The more the info the better.
    Updating the parameters on those tables should help. If still doesn't work then you should check another parameter using transaction RZ10 or report RSPARAM.
    If my info solves your problem, points are appreciated, if not, we will try...
    Jose

  • How to display user ids having non aplabetics

    Hi,
    I want to display user ids which are having non alphabetics.
    CREATE TABLE TEST(USERID) AS
    select 'ALINDSTRÖM' from dual union all
    select 'ANÄSVALL' from dual union all
    select 'JAMES' from dual union all
    SELECT 'BLINDÉN' FROM DUAL UNION ALL
    SELECT 'SEKHAR' FROM DUAL;
    Expected output is:
    USERID
    ALINDSTRÖM
    ANÄSVALL
    BLINDÉN
    Abover id's having non alphabetics like Ö,Ä,É. Please help me.
    Iam using oracle 10g

    SQL> CREATE TABLE TEST
      2  as
      3 
      3  select 'ALINDSTRÖM' userid from dual union all
      4  select 'ANÄSVALL' from dual union all
      5  select 'JAMES' from dual union all
      6  SELECT 'BLINDÉN' FROM DUAL UNION ALL
      7  SELECT 'SEKHAR' FROM DUAL
      8  ;
    Table created
    SQL> select userid
      2  from test
      3  where regexp_instr(userid,'[^A-Z]',1,1) > 0
      4  ;
    USERID
    ALINDSTRÖM
    ANÄSVALL
    BLINDÉN

  • Sql Devloper 4.0.0.13 - problems with displaying user data types

    Hi,
    I have installed new version of sqldeveloper and have discovered some problems with displaying user data types. The data that is described as VARCHAR2 are displayed with ‘???’.
    The problem persist in table view, script output and exported files.
    My type is described as follows:
    create or replace TYPE "DPTY_ADRESA" AS OBJECT
      ID_DPSF_OPCINE                                         NUMBER,
      ID_DPSF_MJESTA                                        NUMBER,
      OPCINA                                            VARCHAR2(100),
      MJESTO                                            VARCHAR2(100),
      ULICA                                 VARCHAR2(200),
      BROJ                                   VARCHAR2(20),
      SPRAT                VARCHAR2(20),
      OSTALO                             VARCHAR2(100),
      CONSTRUCTOR FUNCTION dpty_adresa RETURN SELF AS RESULT
    add MEMBER FUNCTION dajAdresu RETURN VARCHAR2 cascade;
    when make select column from table that contains this type I get next results:
    CASE 1:
    SQLDeveloper Version 3.2.20.09; Build MAIN-09.87; JDK 1.6.0_43; Windows 7 64 bit
    Select:
    select id, adresalokacija
    from dptr_saglasnosti
    where id = 1;
    Result:
            ID ADRESALOKACIJA
             1 COMP.DPTY_ADRESA(124,4913,'TRAIK','TURBE','BABANA','3452','0',NULL)
    END CASE 1;
    CASE 2:
    SQLDeveloper Version 4.0.0.13; Build MAIN-13.80; JDK 1.7.0_40; Windows 7 64 bit
    Select1:
    select id, adresalokacija
    from dptr_saglasnosti
    where id = 1;
    Result1:
    ID ADRESALOKACIJA
             1 COMP.DPTY_ADRESA(124,4913,'???','???','???','???','???',NULL)    
    But if I select one element it is displayed normal.
    Select2:
    select id, a.adresalokacija.opcina
    from dptr_saglasnosti a
    where id = 1;
    Result2:
    ID ADRESALOKACIJA.OPCINA
             1 TRAVNIK                  
    END CASE 2;
    I have tried this scenario on three different pc with same output.
    Pleas help me to get rid of the '???' in result.
    Best Regards,
    Omer

      I tried on SQLDeveloper Version 4.0.0.13; Build MAIN-13.80; JDK 1.7.0_45; Windows 7 64 bit; NLS setting is default
    all data can show,No ??? in result
    Test step as following:
    create or replace TYPE "DPTY_ADRESA" AS OBJECT
      ID_DPSF_OPCINE                                         NUMBER,
      ID_DPSF_MJESTA                                        NUMBER,
      OPCINA                                            VARCHAR2(100),
      MJESTO                                            VARCHAR2(100),
      ULICA                                 VARCHAR2(200),
      BROJ                                   VARCHAR2(20),
      SPRAT                VARCHAR2(20),
      OSTALO                             VARCHAR2(100),
      CONSTRUCTOR FUNCTION dpty_adresa RETURN SELF AS RESULT
    alter TYPE "DPTY_ADRESA" add MEMBER FUNCTION dajAdresu RETURN VARCHAR2 cascade;
    CREATE TABLE dptr_saglasnosti (
    adresalokacija        DPTY_ADRESA,
      id    number);
      INSERT INTO dptr_saglasnosti VALUES (
      DPTY_ADRESA (65,225,'Vrinda Mills', '1-800-555-4412','sss','aaaa','eeeee','attta'),1 );
    select id, adresalokacija from dptr_saglasnosti where id = 1;
    ID ADRESALOKACIJA
    1    HRCP.DPTY_ADRESA(65,225,'Vrinda Mills','1-800-555-4412','sss','aaaa','eeeee','attta')

  • Displaying user input

    Hi all,
    Does anyone know how to display user input on a different panel, acitivated by a button press.
    For example in panel a, a textfield is declared to collect user input
    addForenametf = new JTextField(20);
              addForenametf.setFont(userInput);
              addForenametf.addActionListener(this);
              //postion button on grid bag
              c.gridx = 1;
              c.gridy = 1;
              addScreen.add(addForenametf, c);..then a button is pressed to take in the data (there are numerous textfields). When this happens the next screen, panel b appears and displays the values of the text field. Thus in the actionlistener...
    ...     else if(c.equals(confirmButton))
                               String forenameS = myContactMel6.getForename();
                             middle.removeAll();
                    middle.add(confirmScreen);
             }..then in the panel confirmScreen i try to display the string forenameS
         JLabel displayForename = new JLabel("");
              displayForename.setText(forenameS);
              //position button on grid bag
              c.gridx = 0;
              c.gridy = 2;
              confirmScreen.add(displayForename , c);     ...have also tried instead directly accessing the textfield as below but still doesn't print anything
         JLabel displayForename = new JLabel("");
              displayForename.setText(addForenametf.getText());
              //position button on grid bag
              c.gridx = 0;
              c.gridy = 2;
              confirmScreen.add(displayForename , c);Thank you ver much in advance!

    You need to pass in the information to your confirmation panel. One option would be to create a new instance of the confirmation panel each time the user selected the button. In this case you should pass in each value to be displayed to the constructor. Otherwise, you could have a method that accepts all the data needed and it fills the correct text fields. I am assuming that panel a has access to an instance of panel b so that it can pass the data in.

  • Maxl statement (display user in group all;) is not working.

    Hello,
    Hyperion version 9.3.1 upgraded to 9.3.3. Not sure the below issue is because of this
    I have an interesting issue with a maxl statement : "display user in group all;". When I execute this statement through command prompt doing essmsh, it does give out any records and also doesn't end. I will have to end it with ctrl+c.
    When I execute it through EAS console, then EAS console just hangs.
    But, if I try to retrieve the users from groups individually ( I mean "display user in group 'examplegrp';"), then its working fine and throwing out the records.
    It is giving me a hard time and my dumb mind not able to figure it out.
    Any ideas please?
    Thanks

    Hi CL, Yes I ran it on the Essbase Server. We actually set it up through a scheduled batch script which was perfectly fine till last month (I guess). We noticed this just a week ago. The only change we had in our environment is that we upgraded 9.3.1 to 9.3.3 recently. Not sure whether it is making any difference.
    Thanks,
    KK

  • What is going on with all my apple device. Facebook keep displaying users or friend in wrong display picture and today uses my friend picture to display my I D...what is going on. A bug or what?

    What is going on with all my apple device. Facebook keep displaying users or friend in wrong display picture and today uses my friend picture to display my I D...what is going on. A bug or what?

    IPad and IPhone 4

  • Display user-submitted content by date

    Is it possible to display user-submitted content (Using Web Apps Input Form) by date with most recent at top of list, instead of by alphabetical order? https://unihub.worldsecuresystems.com/acctg-101-1/acctg-101 Please create user to view.

    Hi,
    You can customize the list view in Admin > Site Manager > Module Templates > Web App Layouts > List Layout to also include {tag_releasedate}.
    Then, on a page, from the module toolbox, select Web Apps> List of Web App Items > you can choose the "Latest Items"
    Kind Regards,
    Alex

  • Display user login id on report

    Hi,
           I need to display user login  id on a report and also if needed i want to use it as a prompt.
           Let me know how I can achieve this.
           Thanks in Advance!!

    Gangise,
    to display user login id on a report
    =CurrentUser()
    to use it as a prompt
    In the Designer software you have access to @variable('BOUSER')
    Thanks,
    John

  • Displaying User groups in ACS 4.2

    Is there an easy way to display User groups similar to NDG's?

    Is there an easy way to display User groups similar to NDG's?
    Hi,
    Unfortunately there is no view like viewing NDG in ACS 4.2, Yes you can see different gropus configured in ACS when you go into Group setup and by drag down option you can view the number of groups configured in ACS.
    Hope to Help !!
    Ganesh.H
    Remember to rate the helpful post

  • Security report SEC_LIST_MBR is not displaying users list

    Hi,
    When we run security report SEC_LIST_MBR. It is not displaying list of users instead it is just displaying user id who ran the report all other columns Full Name, Teams, Task Profile and Member access are blank.
    Please suggest what is causing it not to display list of users.
    In database we loaded the following page  http://ReportServer/reports and ran report SEC_LIST_MBR. It also gave same result - one row with user id data only.
    Regards,
    Rajesh

    We found the root cause it was because table "task" does not have records in APPSERVER Database.
    Once we updated task table. Security report SEC_LIST_MBR is displaying results correctly.
    Regards,
    Rajesh

  • Displaying User information

    Hi!
    When i use any iview to display user information, i get in the user name fiel de id user instead of the user name.
    It is the same for all the place where the portal use the user infomation display (CLP, search user, roles search, etc).
    Is anybody knows how to change this?
    I thank you in advance.

    Customizing Users' Display Name
    Use
    A user’s display name is the friendly name that is displayed for a user in most user interfaces, for example in list of results when you search for a user in the UME administration console. Programmatically, it is the name that is returned by the method IUser.getDisplayName().
    By default the display name is the user’s last name followed by the first name. It is possible to customize it, to display a different friendly name, for example the users salutation followed by first name and then last name.
    Procedure
    The name returned by the method IUser.getDisplayName() is calculated by the user attributes specified in the user management property ume.users.displayname_template.
    The default value is ume.users.displayname_template=,
    To change the display name, change the value of this property. It can be a combination of:
    u00B7        User attributes: The available user attributes are: , , , , , , , , , , , , , , , , , , ,
    u00B7        Characters: Most characters whose unicode lies between \u0020 and \u007E can be written as they are. These are characters such as A-Z, a-z, commas, semicolons, and so on.
    u00B7        Unicode characters: Characters whose unicode does not lie between \u0020 and \u007E, must be written in the form \uXXXX
    Example
    You change the value to:
    ume.users.displayname_template=
    For a user whose first name is ‘Peter’, second name is ‘Miller’ and salutation is ‘Mr’, the display name would be ‘Mr Peter Miller’.
    This display name would appear on all user interfaces that use the method IUser.getDisplayName().
    attributeMapping>
    If you are using an LDAP directory as a data source for your user-related data, the ‘logical’ attribute names used by the Java application programming interface (API) of SAP User Management Engine (UME) must be mapped to the ‘physical’ attribute names used in the schema of your corporate LDAP directory.
    In the preconfigured files shipped with UME, the logical attributes of the Java user management API are mapped to the physical attributes used for the object class inetOrgPerson in the X.500 standard. If you use this standard without any modifications, you will not need to change the attribute mapping data. If you have extended this object class in your LDAP directory, or use a different object class, you can flexibly add additional attributes to the attribute mapping data or change the attribute mapping data as required. By providing you with the means to map attributes, UME allows you to use any schema that suits your company’s requirements.  
    The following examples illustrate scenarios where you need to change the attribute mapping data:
    The logical attribute for a user’s e-mail address used by the user management component is named email, but the physical attribute in the schema for your corporate LDAP directory is named mail. You must map email to mail in the configuration file.
    In your company, you wish users to log on with their e-mail address and password instead of with their user ID and password. In a user account, the logical attribute j_user defines the logon ID. By default this attribute is mapped to the unique ID (uid) of a user. By mapping j_user to the physical attribute for the user’s e-mail address, for example mail, users can in future log on with their e-mail address.
    For a list of the set of fixed logical attribute names used in the API, see Logical Attributes.
    Example
    <dataSources>
    <dataSource id="CORP_LDAP"
        className="com.sap.security.core.persistence.datasource.imp.LDAPPersistence"
        isReadonly="false"
        isPrimary="true">
      <responsibleFor>
        <principal type="account">
        </principal>
        <principal type="user">
          <nameSpaces>
            <nameSpace name="com.sap.security.core.usermanagement">
              <attributes>
                <attribute name="firstname" populateInitially="true"/>
                <attribute name="displayname" populateInitially="true"/>
                <attribute name="lastname" populateInitially="true"/>
                <attribute name="fax"/>
                <attribute name="email"/>
                <attribute name="title"/>
                <attribute name="department"/>
                <attribute name="description"/>
                <attribute name="mobile"/>
                <attribute name="telephone"/>
                <attribute name="streetaddress"/>
                <attribute name="uniquename" populateInitially="true"/>
              </attributes>
            </nameSpace>
          </nameSpaces>
        </principal>
          <principal type="group">
          </principal>
      </responsibleFor>
      <attributeMapping>
        <principals>
          <principal type="account">
          </principal>
          <principal type="user">
            <nameSpaces>
              <nameSpace name="com.sap.security.core.usermanagement">
                <attributes>
                  <attribute name="firstname">
                    <physicalAttribute name="givenname"/>
                  </attribute>
                  <attribute name="displayname">
                    <physicalAttribute name="displayname"/>
                  </attribute>
                  <attribute name="lastname">
                    <physicalAttribute name="sn"/>
                  </attribute>
                  <attribute name="fax">
                    <physicalAttribute name="facsimiletelephonenumber"/>
                  </attribute>
                  <attribute name="uniquename">
                    <physicalAttribute name="uid"/>
                  </attribute>
                  <attribute name="loginid">
                    <physicalAttribute name="null"/>
                  </attribute>
                  <attribute name="email">
                    <physicalAttribute name="mail"/>
                  </attribute>
                  <attribute name="mobile">
                    <physicalAttribute name="mobile"/>
                  </attribute>
                  <attribute name="telephone">
                    <physicalAttribute name="telephonenumber"/>
                  </attribute>
                  <attribute name="department">
                    <physicalAttribute name="ou"/>
                  </attribute>
                  <attribute name="description">
                    <physicalAttribute name="description"/>
                  </attribute>
                  <attribute name="streetadress">
                    <physicalAttribute name="postaladdress"/>
                  </attribute>
                  <attribute name="pobox">
                    <physicalAttribute name="postofficebox"/>
                  </attribute>
                  <attribute name="preferredlanguage">
                    <physicalAttribute name="preferredlanguage"/>
                  </attribute>
                </attributes>
              </nameSpace>
            </nameSpaces>
          </principal>
          <principal type="group">
          </principal>
        </principals>
      </attributeMapping>
    </dataSources>
    In the above example, the section on the data source CORP_LDAP contains all the configuration data for the LDAP directory.
    The section on <responsibleFor> defines which data is stored in the LDAP directory and in particular the logical attributes that are stored in the directory. For each attribute listed here, there must be an entry in the attribute mapping section.
    By default the section on <attributeMapping> contains attribute mapping data for the object class inetOrgPerson in the X.500 standard. Here you can modify the physicalAttribute name (the attribute name in the LDAP directory) or you can add an additional attribute mapping for attributes outside of inetOrgPerson that you have added to your LDAP schema. 
        <attribute name="firstname">
            <physicalAttribute name="givenname"/>
        </attribute>
    Even if the physical and logical attribute name are identical, you should map them. For example, in the above example, displayname maps to displayname.
    If an attribute is not mapped, the API will not have access to this data.
    Some logical attributes are mapped to "null". This means that the API uses this logical attribute, but the logical attribute does not map to a physical attribute. Instead it maps to a computed value.
    Ensure that all inetOrgPersons in your LDAP directory contain a valid value for the attribute uid. In the default configuration, this attribute is used to search for users for display in user-management applications such as the role assignment tool.
    Alternatively, change the attribute mapping so that uniquename is mapped to cn instead of uid.
        <attribute name="uniquename">
            <physicalAttribute name="cn"/>
        </attribute>
    In this way, cn is used to search for users for display in user-management applications.
    Namespaces
    Another useful feature is that you can map logical attributes to different physical attributes depending on the namespace. For example, an application in the namespace com.mycompany.app1 might use the physical attribute uid as displayname, whereas another application com.mycompany.app2might use the physical attribute sn as displayname. This would be mapped as follows:
      <attributeMapping>
        <principals>
          <principal type="user">
            <nameSpaces>
              <nameSpace name="com.mycompany.app1">
                <attributes>
                  <attribute name="displayname">
                    <physicalAttribute name="uid"/>
                  </attribute>
                </attributes>
              </nameSpace>
              <nameSpace name="com.mycompany.app2">
                <attributes>
                  <attribute name="displayname">
                    <physicalAttribute name="sn"/>
                  </attribute>
                </attributes>
              </nameSpace>
            </nameSpaces>
          </principal>
        </principals>
      </attributeMapping>
    You need to meintain this property in the sapup.properties file.
    Therefore in the portal you select: System Administration ->
    System Configuration -> UM Cinfiguration -> Direct editing.
    Then you add the property in the textfield, save and restart the
    J2EE Engine in order to activate this value.
    Best regards,
    Patricio.

  • Display User Sessions

    Hello everyone!
    With the transition SM04 I can display all the users active in the system who are logged on. I need to display users with name of workstation at witch the user is working who are logged on during the day and set up a filter such a way that display only those users, who worked from different workstations during the day. Any ideas?
    Tnx a lot for your help!

    Just a quick note. Terminal name can be spoofed. I think it comes over as part of SAP DIAG protocol. I played with protocol few years ago and I think you can simply replace host name when you have control over network.
    I also vote for security audit log. That's the only reliable source of information.
    Cheers

  • Display User access

    It's incredible it's so <b>hard</b> to display user logged on the portal environment...
    I need to display users id in a period of time...
    Any can help me?
    <b>EP6 SP2 Patch30</b>
    Thanks!

    Hi Daniel,
    sorry but I think that a user logged "<i>story</i>" is so important!
    I'm using EP6 Sp2 Patch 30 on J2EE 6.20 Patch 30 with Oracle...
    around patch 5 there was something on monitoring to see the user ID logged from a date to a date... but now...
    I tried something on PerfMonitor... but It's not so clear to find user id... the same is for the usermanagement.log...
    is there any way to have a very easy log file???

  • Display user using complex selection criteria

    How to display user using complex selection criteria, I want to display user list with company code assigned to them?

    In t.code SUIM
    Select Users by complex selection criteria in that selection of values in authorization object give F_BKPF_BUK enter and then specify the company code & execute.
    It will give list of roles having company code. Highlight each role and click on user assignment.
    hope this helps

Maybe you are looking for