Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    New to the CF scene
    Join Date
    Nov 2011
    Posts
    9
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Arrow ajax space problem

    Hello,

    Currently, i am working on a website. I need that when the data comes from ajax in the div or span tag, it should take space by moving down the data already present there without overwriting it.

    But it doesnot happens. When i get data through ajax, then it overwirtes the previous data which was already present there and doesnot move the previous data downwards.


    Any help plz

  • #2
    Senior Coder
    Join Date
    Dec 2010
    Posts
    2,391
    Thanks
    11
    Thanked 568 Times in 561 Posts
    Your code please

    It's your code (and not ajax) which overwrites data

  • #3
    New to the CF scene
    Join Date
    Nov 2011
    Posts
    9
    Thanks
    1
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by devnull69 View Post
    Your code please

    It's your code (and not ajax) which overwrites data
    how can i prevent it from overwriting data.
    Whenever i fetch data, it gets overwritten on the previously present data.
    What to do with it ?

  • #4
    Senior Coder
    Join Date
    Dec 2010
    Posts
    2,391
    Thanks
    11
    Thanked 568 Times in 561 Posts
    Generally there is an assignment operator = and an append operator += for strings. The latter will not overwrite.

  • #5
    New to the CF scene
    Join Date
    Nov 2011
    Posts
    9
    Thanks
    1
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by devnull69 View Post
    Generally there is an assignment operator = and an append operator += for strings. The latter will not overwrite.
    You didnt understand.
    i have a span section like

    <span id="data"> </span>
    Below this i have div section. like

    <div id="imgs"> <img src="1.jpg"> </div>
    Now when ajax get executed fetches large amount of data, then it overwrites the data in the div tag i.e. image. I want that, the fetched data should not overwrite the div section data, but div section data should move downwards when ajax data fetched..

  • #6
    Senior Coder
    Join Date
    Dec 2010
    Posts
    2,391
    Thanks
    11
    Thanked 568 Times in 561 Posts
    You didn't understand

    Give us your code ... we cannot know out of thin air. To a general question you got a general answer which is still correct even for your new (a little less general) question.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •