Replace content in CFHTTP content

We are using CFHTTP to grab some content from a sister site
of ours. When displaying the cfhttp.FileContent we want to remove
certain elements from the page. The problem is the elements to
remove are often large chunks of code as opposed to just a word
here and there. I tried doing a cfsavecontent variable and replace
the cfhttp.FileContent stream with the cfsavecontent variable but
it doesn't want to work. Is there an easier way to do this? Like
specify a starting point of the chunck of code to remove and an end
point and removing everything from the start to the end point from
the cfhttp stream?
THANKS

thanks guys, ok so here is the URL I am usng in the CFHTTP:
http://www.truckpaper.com/listings/forsale/list.asp?pcid=391030&etid=1&bcatid=27&dlr=1
I would liek it to ONLY return the search results table. So I
need to remove the header information at the top and the search
form and everything else at the bottom. So the first thing you will
see is the beige table row with the column headers and the last
thing you will see is the links to go to the next two pages.
The blocks you wish to replace contain arbitrary spaces,
perhaps even dynamic elements. I don't think it is advisable to use
the cfsavecontent tag. In string search and replacement, every
character counts. It is surgery by laser.
What you need here is an axe. For example, if you chop off
the contents of the first form and the last two forms, you will get
a result close to what you seek.

Similar Messages

  • Smart Objects: How can I prevent resizing when replacing contents?

    There seem to be 2 kinds of smart objects:
    One kind where you can replace the contents, no matter what size it has and it will fit into the bounding box of the smart object which is already there.
    The other kind where this doesn't happen.
    Is there any way to control that behaviour? I found that in older PS-files, replacing contents always made the new content fit into the bounding box, but since CS3, the transformation stays the same which means I have to rescale the smart-object if the content-size has changed.
    Example:
    Imagine a game cover with screenshots on the back side. Now each screenshot is a smartobject.
    All Screenshots are at 640x480 (assumend the standard screen dpi of 72)
    Now I found them in a better resolution (1024x768, also 72dpi) and replace the old ones with "replace content".
    The old photoshop behaviour: Photoshop would fit the larger image to occupy exactly the same area than it's predecessor.
    The new behaviour: The whole Smartobject is enlarged by 160% (not the transformation parameters, the visual appearance.), I have to scale it down to make it fit to the old size.
    And I really wonder about having older and newer Photoshop-Files where these Smartobjects behave differently.
    Now did I miss something in the help section or is there a way to control this behaviour?

    Yes, fortunately, I am a Windows user, but I don't want to start a religious war here And it is also possible to run multiple versions of Adobe products simultaneously under Windows - why shouldn't that be possible? Currently I have CS3 and CS4 and somtimes use CS3 when CS4 is just too buggy to get the job done. Before that I had CS and CS2 on the same machine.
    But I wouldn't keep all versions back to PS 6.0 or CS, that would be a bit too chaotic and I'd had to spend days of installing if I get a new computer. I expect those programs to be a little bit backwards-compatible, so I don't have to use many different versions. And for Photoshop, this is mostly the case. It's just very tiny details like Smart Object resizing that seems to work differently.
    Otherwise I'm really happy that in CS4 I can finally link Masks to smart objects and apply warp and perspective on them, that's a big plus!

  • Replace content of multiple Smart Objects

    Here's simplified version of my dilemma: (Photoshop CS5.1)
    A file contains 3 instances each of 2 unique Smart Objects. Is it possible to Replace Contents of all 6 objects so that they share a common source content?
    Seems simple. Doesn't work.

    The only other thing I can suggest is to post in the Photoshop Scripting forum to see if the scripting wizards there have a script to solve your issue. 
    (I couldn't script my way out of a paper bag myself.)
    http://forums.adobe.com/community/photoshop/photoshop_scripting

  • HELP I have lost all my motion 4 content from all the files, ive looked in all the files and they are all empty. can i get replacement content as I my dvds where stolen along. with my other laptop.

    HELP I have lost all my motion 4 content from all the files, ive looked in all the files and they are all empty. can i get replacement content as I my dvds where stolen along. with my other laptop. any Ideas. would be a great help. For Motion 4.

    Try a hard reset:- hold the home button AND the power switch - ignore the red "Slide to power off" and wait ubntil the iPhone powers down, and then restarts - at the Apple logo, release all the buttons and see if your contacts reappear.

  • Action for Replacing Contents of a Smart Object

    I am using CS5/PS to create a collage created of several images (smart object layers) that I have positioned using individual clipping masks.
    I would like to be able to replace the contents of the images, which I can do via Layer>Smart Objects>Replace Contents...,   but I'd like to have an action for a "one-click" process instead of three clicks.  Problem is, when I try to record the action, it requires me to complete the replacement, and then the action gets hard-wired to replace the image used in the action "record", and therefore doesn't allow me to select which image I'd like to use.
    This functionality is available in PS Elements, so I believe it can be done.  I'm sure I'm missing something pretty basic, I just don't know what!!
    Thanks in advance,
      Brian

    »The separate Photoshop Windows and Macintosh forums will become Read Only on Tuesday, January 3rd.«
    Have you checked the »Toggle dialog on/off«-checkbox beside the item in the Actions Panel?

  • How to replace content in text data type?

    How to replace content in text data type? 
    when we sending the mails we are taking content from the database.
    The data is maintained in text data type column. Now i have to replace some of content in mail content
    (text data type column) from database. 
    I tried by using REPLACE function but data is truncated

    The data is maintained in text data type column.
    Hello,
    See REPLACE (Transact-SQL) => "If
    string_expression is not of type varchar(max) or
    nvarchar(max), REPLACE
    truncates the return value at 8,000 Bytes"
    You may should consider to Change the data type from "Text" (deprecated) to NVarChar(max).
    Otherwise you have to use
    UPDATETEXT (Transact-SQL) for the text data type.
    Olaf Helper
    [ Blog] [ Xing] [ MVP]

  • Replace content smart objects doesnt work properly.

    Hello fellow Photoshoppers,
    Currently i am working on reusable album templates with smart objects. At first i was very enthusiastic but this was soon to end. as the replacing doesnt work properly.
    I made the smart object by using:
    1. > file
    2. > place
    then i try to replace the content by using.
    1. > layer
    2. > smart objects
    3. > replace contents
    the old image should get replaced by the chosen file and matching size, smart layers etc. However when i perform the same actions my image gets replaced but it is not the same size as the smart object it replaced. This makes the entire template useless as it would take far too much time resizing every single image. inspired by another video I also tried double clicking the layer and tried replacing the image in the editing sceen by dragging another file on top of the smart object. Again, it does not spread out to the full smart object size and i'm stuck with a small image in need of extra work.
    Needless to say, very frustrating.
    Any thoughts?

    Are you sure you understood how it is intended work?
    That is an interesting question, i have no experience with photoshop as i bought CS5,5 just a week ago and have no experience with any of the previous versions either. All info regarding how to make such a template i found from various tutorials, i posted one below. When they do it the image get scaled perfectly. Now since they use some smart filters in the tutorial i applied them aswell to see if this would fix the problem but it did not.
    http://www.picturesocial.com/video/wedding-photo-album-templates
    Are the images you want to switch in at least always of the same width to height-relation?
    I checked both files for consistency and discovered they were shot on different camera's. One file ( the origional smart object ) was cropped form a 21,0MP file and the other was croped from a 10,1 MP file. Both images were cropped to a 2x1 ratio. Having discovered the difference in pixel amount i cropped a different 21,0 MP file to 2x1 ratio and checked both files for their exact dimensions (both images are equal in size with 5616 x 2808 pixels) and replaced the content with the newly cropped file which gave a much better result. However, the image was slightly smaller in photoshop leaving a small gap where the origionally placed smart object lined up perfectly. I turned the situation around and placed the 10,1MP cropped image as the smart object and replaced the content by a 21,0 MP cropped image. As to be expected i ended up with a new image much larger then the smart object. So the smart object does not constrain the files to the dimensions set. As it turns out it only scales the replaced content relative to the size of the origional content of the smart object.
    I just need a reusable template with objects that:
    - cannot be moved once locked ( if possible) but can have its content replaced
    - scales the replaced content to the predefined dimensions
    - needs no prework like cropping to the same aspect ratio as the smart object content. ( i want to be able to place a landscape sized raw (3x2) on any landscape format  (2x1 / 16x9 / 4x3 or whatever) i find it acceptable to having to crop a portret to landscape orientation first before being able to replace a landscape.
    now ive been searching for more info and some people say indesign is much faster in making album pages so I am installing the program as we speak hoping this will be the solution.

  • Best way to replace contents of a layer with higher res image

    I can do it, but I was wondering if there is a better way.
    Large PS file (CS6 and CC) half a dozen texture layers using low res images. Several have blend modes, transparency and even masks. I now have the same images in high res. I want to replace just the image, but not lose my blend/transparency, or masks.
    Any thoughts?
    Do I bring in the high res layer, copy the mask over etc? Then delete the original?
    Max

    Try this.
    Convert the low res images to Smart Objects. Layer > Smart Objects > Convert to Smart Object.
    The replace the contenst of the smart objects. Layer > Smart Objects > Replace Contents...
    This way you can replace the low res images with the hi res versions. Provided they are the same crop and aspect rarion your mask should be fairly good to go. I say fairly good as you may have made some adjustments (eg. feathering) based on the resolution.
    The blend modes and transparency will be unaffected.

  • Apple script to replace content in specific folders with folder names in csv

    Can anyone please help me with this scenario... It would greatly be appreciated!
    1. I have a list in csv containing 3 columns: Column 1 = Folder name • Column 2 = Entry A • Column 3 = Entry B
    2. I have 100 folders named the same as Column 1.  in each folder there is different files.
    This is what I need.
    I need the script to to find the folder based upon column 1.
    Then the script should search for place holder named "Entry A" and replace it's contents with data from Column 2.  There are several files with in the folder that contain place holder "Entry A" so it should replace it all but must remain with in that folder.
    Then same for column 3 find place holder named Entry B and replace.
    Then it should save all files.
    Any help is greatly appreciated!  Thank you!

    Can anyone please help me with this scenario... It would greatly be appreciated!
    1. I have a list in csv containing 3 columns: Column 1 = Folder name • Column 2 = Entry A • Column 3 = Entry B
    2. I have 100 folders named the same as Column 1.  in each folder there is different files.
    This is what I need.
    I need the script to to find the folder based upon column 1.
    Then the script should search for place holder named "Entry A" and replace it's contents with data from Column 2.  There are several files with in the folder that contain place holder "Entry A" so it should replace it all but must remain with in that folder.
    Then same for column 3 find place holder named Entry B and replace.
    Then it should save all files.
    Any help is greatly appreciated!  Thank you!

  • Incoming email replaces content with contents from old email already in inb

    This morning for no apparent reason, incoming email has its content replaced with the entire content from seemingly random emails received months ago. It also replies the sender email to that attached to the old content.
    What could be happening here?

    Hello, and welcome to the Discussions.
    This is an indexing problem. Are you using any plugins or add on software for Mail? Any anti-virus or internet software, or backup software that is not Apple?
    If only noticed in the Inbox, then open the Inbox (for one account only, if more than one account is setup), click on Mailbox in the Menubar, and choose Rebuild. Rebuild repairs the universal index that Mail uses, but be aware that at one point in its operation, all message will disappear from the list of messages before all reappear. It can take several minutes if there are lots of messages.
    Is this account POP or IMAP, btw? I ask this because you should not use the method Mulder recommended if using an IMAP account, without additional steps.
    Ernie
    Message was edited by: Ernie Stamper

  • Replace content on used iPod with mine?

    My iPod touch 2G recently died and I got my sister's old iPod, also a 2G. How do I go about wiping it and replacing her content with mine? Do I "erase all settings and content", then sync to my iTunes like normal?  If I just sync like normal, will ALL of my data from my old iPod still be there, or just program-inherent data? Can I/should I replace with backup data?
    Thanks!
    AR

    Connect her iPod to your computer and restore her iPod from the backup of our iPod.
    See:
    iTunes: Backing up, updating, and restoring iOS software

  • Search and replace, contents from excel file

    Hi
    I have the list in the excel file which needs to replace. The script should read the excel then replace to the opened InDesign documents.
    The excel(*.xls) file has two columns, first column has old nos. and the second column has the new numbers to replace.
    Ex:
    Column 1               Column 2
    (Search)               (Replace)
    4257/2          =>               1/2
    4257/3          =>               1/3
    4257/4          =>               1/4
    3257/2          =>               1/5
    3257/3          =>               1/6
    3257/4          =>               1/7
    4457/4          =>               2/2
    4457/5          =>               2/3
    4457/6          =>               2/4
    4457/7          =>               2/5
    Thanks in Advance,
    Thiru

    @csm_phil:
    this is a very radical method, because:
    1. you don't limit your changeGREP() to a specific table column (possibly the searched texts are found in other strings around the document and changed as well!)
    2. you are in trouble if a certain value you want to change exists more than one time (not likely, but who knows?) and you want to change it in diffrent values per instance. That will fail.
    If we deal with only ONE column of ONE table, to address issue 1 I would ask the user to select the column of the table and instead of:
    app.documents.item(0).changeGrep();
    I would use:
    app.selection[0].changeGrep();
    I don't hope issue 2 will apply in this case.
    @mr. pathi:
    However, in the case of only one column of one table to change AND if the new excel file contains ALL entries in the exact order (both all old and all new values), you could change the contents of the column by copying from excel to InDesign. No script necessary. The formatting of the old cells will be retained.
    You cannot do that by placing the new table to InDesign and copy/paste the new column to the old one, because the formatting of the copied column will be transferred as well (paste without formatting is not an option here).
    Uwe

  • Mail replaces content of new messages with those of very old messages

    Hi all,
    In the last day or so, the content of new emails have been replaced by contents of old messages from long ago. The listing in the inbox stays intact, but when I view it both the message body and the from/subject/cc line (in the viewing window) is changed.
    I know this problem is specific to my computer since all of my mail displays correctly on my iPhone. This problem is also specific to one of my two email accounts-- an IMAP account from my own domain.
    Is this a cache issue? Something else?
    Thanks,
    Matt

    Hi irwincine,
    I think you'll find the info in this post useful, and might resolve your problem with mail. http://discussions.apple.com/thread.jspa?threadID=121902

  • IPad won't let me sync music without replacing content

    I just restored a new iPad from a backup on my computer. It recovered my settings, all my pics, & files beautifully except it didn't restore the music. So when I try to sync music now I get this message:
    Are you sure you want to sync music? All existing content on the iPad “xxx's iPad” will be removed and replaced with songs and playlists from your iTunes library.
    Any idea how to put the tunes back on my iPad without replacing the existing content?

    If this is the very first time you've connected your iPhone to a computer, it will ask you if you want to set it up as new or restore a backup. If you set up as new, it won't erase anything, and will create a backup and allow you to sync

  • Replacing Content

    I do know a bit about web design, but not a lot yet. I'm
    redesigning my portfolio site, [url]www.alexwillms.com[/url].
    I've decided to go the one-page route this time. My question
    is this: I've created a graphic of a picture frame on a wall, and
    one way or another I need to replace the image inside it. This will
    probably be done by clicking on thumbnails or "next" and "previous"
    buttons. How, from a Dreamweaver point of view, do I execute this
    replacement of content?
    The other option might be to create one long page with all
    the different images, and have it scroll horizontally when the user
    clicks on the corresponding thumbnail. Sort of like www.youlove.us.
    I'm not sure how to do that either, though.
    EDIT: I see that a similar question was just posted.
    Nevertheless, any help would be appreciated, especially having to
    do with the scrolling.

    > I've decided to go the one-page route this time.
    What does that mean?
    > How, from a Dreamweaver point of
    > view, do I execute this replacement of content?
    You could do it with Spry, or with the SetText behavior. The
    latter allows
    you to 'dynamically' rewrite the code for an element with an
    ID. So, your
    picture frame could be the background image for a container
    div, and the
    SetText behavior could write the image tag into that div
    depending on which
    link were clicked.
    But honestly, your very best bet would be to get one of the
    slideshow
    extensions from PVII (
    http://www.projectseven.com/)
    - they are the best I
    have seen.
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    http://www.projectseven.com/go
    - DW FAQs, Tutorials & Resources
    http://www.dwfaq.com - DW FAQs,
    Tutorials & Resources
    ==================
    "blenditall" <[email protected]> wrote in
    message
    news:gj49bs$kb4$[email protected]..
    >I do know a bit about web design, but not a lot yet. I'm
    redesigning my
    > portfolio site, [url]www.alexwillms.com[/url].
    >
    > I've decided to go the one-page route this time. My
    question is this: I've
    > created a graphic of a picture frame on a wall, and one
    way or another I
    > need
    > to replace the image inside it. This will probably be
    done by clicking on
    > thumbnails or "next" and "previous" buttons. How, from a
    Dreamweaver point
    > of
    > view, do I execute this replacement of content?
    >
    > The other option might be to create one long page with
    all the different
    > images, and have it scroll horizontally when the user
    clicks on the
    > corresponding thumbnail. Sort of like www.youlove.us.
    I'm not sure how to
    > do
    > that either, though.
    >

Maybe you are looking for