Backgrounds from images in database

I've been working with images lately, and I'm trying to do the following:
Users can upload images that adhere to my restrictions (ie, size, filetype, etc). What I would then like to do with those images is set the users profile background to be the image itself. I need this to be dynamic, ie, no hard coding of image ids or anything like that. Is it possible to dynamically determine the page background using images in the database? My theory is I may need to create a custom template for the profile page to do this but I'm not sure. Does anyone have experience with this?

fac586 wrote:
>
Welcome to the forum: please read the FAQ and forum sticky threads (if you haven't done so already), and update your profile with a real handle instead of "user12612539".
When you have a problem you'll get a faster, more effective response by including as much relevant information as possible upfront. This should include:
<li>Full APEX version
<li>Full DB/version/edition/host OS
<li>Web server architecture (EPG, OHS or APEX listener/host OS)
<li>Browser(s) and version(s) used
<li>Theme
<li>Template(s)
<li>Region/item type(s) (making particular distinction as to whether a "report" is a standard report, an interactive report, or in fact an "updateable report" (i.e. a tabular form)
With APEX we're also fortunate to have a great resource in apex.oracle.com where we can reproduce and share problems. Reproducing things there is the best way to troubleshoot most issues, especially those relating to layout and visual formatting. If you expect a detailed answer then it's appropriate for you to take on a significant part of the effort by getting as far as possible with an example of the problem on apex.oracle.com before asking for assistance with specific issues, which we can then see at first hand.Thank you for the response, but you are right, I did leave some info out. Take two:
I'm using the online Apex workspace, so the version is 4.2 Currently, I'm using the new theme throughout my application, Theme 26 (Which is actually really nice). The images are going to be displayed on the users profile page, which is composed of the following:
-An HTML Region containing several text fields, which show the users information
>
I've been working with images lately, and I'm trying to do the following:
Users can upload images that adhere to my restrictions (ie, size, filetype, etc).It would help us to help you if you explained what you'd been doing with these images, how they are uploaded, where they are stored etc.At the moment, the images are simply stored in the database in a BLOB column. They will have no other use other than being used as backgrounds. Users can only have one image uploaded at a time. They are uploaded via the built in APEX item "File Browser".
>
What I would then like to do with those images is set the users profile background to be the image itself. I need this to be dynamic, ie, no hard coding of image ids or anything like that. Is it possible to dynamically determine the page background using images in the database?Yes.
My theory is I may need to create a custom template for the profile page to do this but I'm not sure.That's possible, but probably more work than is necessary. Customized styling of individual pages can be applied using Page Attributes&mdash;precisely how is dependent on the APEX version used, hence the requirement for you to provide this information.Hopefully the above information clarifies my problem a little. In the meantime, I will look at the link you posted about page attributes. Thank you.

Similar Messages

  • Image Gallery from images in database.

    Hi,
    I am developing image gallery from images stored in oracle database.
    I am using JQuery ColorBox plugin (http://www.jacklmoore.com/colorbox/example1/) and I need to specify image in href for plugin.
    My JSP page (http://localhost:8080/gallery/show_image.jsp?id=1) fetch image from database and show.
    I can see image in browser when I run url http://localhost:8080/gallery/show_image.jsp?id=1.
    But following not working when JSP page specify in href.
    <h2>No Transition + fixed width and height (75% of screen size)</h2>
    class="group3" href="http://localhost:8080/gallery/show_image.jsp?id=1">Grouped Photo 1</ a>
    class="group3" href="http://localhost:8080/gallery/show_image.jsp?id=2">Grouped Photo 2</ a>
    class="group3" href="http://localhost:8080/gallery/show_image.jsp?id=3">Grouped Photo 3</ a>
    class="group3" href="http://localhost:8080/gallery/show_image.jsp?id=4">Grouped Photo 1</ a>
    class="group3" href="http://localhost:8080/gallery/show_image.jsp?id=5">Grouped Photo 2</ a>
    class="group3" href="http://localhost:8080/gallery/show_image.jsp?id=6">Grouped Photo 3</ a>
    class="group3" href="http://localhost:8080/gallery/show_image.jsp?id=7">Grouped Photo 3</ a>
    Any solution?
    - Thanks
    Zohaib.
    Edited by: zohaib82 on Oct 30, 2012 2:46 AM
    Edited by: zohaib82 on Oct 30, 2012 2:46 AM

    Hard to say when you don't provide anything actually useful other than "its not working". I can only guess that your JSP needs to set a proper content-type. I would investigate using an image servlet in stead of your JSP:
    http://balusc.blogspot.com/2007/04/imageservlet.html

  • Setting background from image file in NetBeans

    Hello,
    recently I started to use NetBeans to create my applications and I found a little problem - I don't know how to set background in JPanel from a image file (*.bmp, *.jpg, etc.) without writing my own code. I found how to use ImageIcon, but cannot deal with setting background. Anyone know a solution?

    The code that you have to write is a custom JPanel (extend it) and in the paintComponent() method you draw the image you want as a background.
    public void paintComponent(Graphics g)
    super.paintComponent(g);
    g.drawImage(img, 0, 0, null);
    }Where 'img' is an object of type Image (such as a BufferedImage).

  • How to remove background from image?

    Hello folks.
    I am trying to incorporate some business logos into a brochure I am creating. The problem is, most of these logos have a white background. How can I remove this and make a transparent background?
    Thanks!

    Blend modes are your friend. always keep in mind that Multiply, screen and overlay affect the white, black and gray depending which one you choose.
    Attached is a blend mode example from photoshop using a black to white gradient.  The normal layer fills the document with.the blend layers on top with the gradient inverted.
    This example is text naming the solid color backgrounds blended over a gradient.

  • How do I completely remove a background from an image & keep it as a .jpeg?

    Hi , I already know how to remove backgrounds from images, and create a transparent background.  However, I need to be able to use the resulting image in another program  called Scratch.  And as far as I know, it does not accept  .tiff, .pgn, .psd or gifs.
    How do I completely remove that background so that it doesn't show up white in other programs when I save it as a .jpeg?

    Jpgs don't support transparency.  It looks like Scratch may support pngs and other formats, but the transparency may not come through.  From what I've read, you may have to use the transparency brush in Scratch to achive what you want.

  • Remove background from Smart Build images

    Hi,
    I've just started creating my first project with Keynote, and so far it's terrific. The question I have is, is it possible to use the alpha tool, or something similar to remove backgrounds from images that I'm using for a smart builds effect.
    Thanks,
    Dave

    Welcome to the discussions, Decaffeinated1.
    The problem you're seeing is specifically with how Keynote copies images. Neither Pages nor Numbers has this problem. The problem and the solution is described here.
    http://www.keynoteuser.com/news/?p=256
    Basically, your choice is to copy through Pages or Numbers (or iWeb) OR to copy another object which will force Keynote to adhere to the transparency set with Instant Alpha.

  • Having difficulty using quick selection tools to remove background form images. Any help appreciated

    Hello All,
    I am trying to remove background from images using the 3 different selection tools.  I start off fine, but ultimately the entire images keeps getting grabbed which ever tool I am using.  It is easier if you are using a pro version of photoshop and not any of the elements versions?  I have elements 11.
    Thanks
    -Deby

    Accents Accents wrote:
    Whenever I have watched a video of this process, it seems so easy!
    So much depends on the image itself to determine which tool is most appropriate. Another tool to try is the selection brush, where you literally paint in what you want to select.
    Cheers,
    Neale
    Insanity is hereditary, you get it from your children
    If this post or another user's post resolves the original issue, please mark the posts as correct and/or helpful accordingly. This helps other users with similar trouble get answers to their questions quicker. Thanks.

  • Insert Image to table from a Non Database Field

    Hallo,
    db- 9i EE R2
    forms - 6i R2
    OS - W2003
    I have a requirement to upload Images to the database from forms.
    I planned to keep the transaction data and the Images separately in different tables with a reference.
    So, I created the Image field (BLOB)  with a Non Database Field in the Form and use a button to upload the Image. (using READ_IMAGE_FILE).
    I tried to insert the Image to the Actual Image table in PRE-INSERT Trigger at block level.
    But I was not able to Insert the using reference method.  (Cannot compile the PRE-INSERT)
          INSERT INTO IMAGE_TB (ID,IMAGE)
           VALUES (IMAGE_SEQ.NEXTVAL, :ITINERARY_MAP.IMAGE);
    So, Please help me to insert a image to different table from a Non Database Field?
    Thanks

    I don't think it will work with a non-db-item. But you could create a separate block based on your image_tb-table, use read_image_file on the then db-based-column and then simpy issue a commit_form.

  • Display images from a SQL database

    I want to display images from a SQL database. The images are in a table under a specific column and are stored as a link to the image. How would I display the images from the column in LabVIEW?
    I'm using LabVIEW 2013 version 13 and SQL Server 2012
    Paul Power
    I have not lost my mind, it's backed up on a disk somewhere

    Hi PauldePaor,
    I hope you are well.
    Once you have pulled the data from the database into LabVIEW in a string form (or path), you can simply use the Read BMP File (Or jpg, png depending on the file type) VI.
    More information can be found here:
    http://digital.ni.com/public.nsf/allkb/02971A30F5D8FC6986256A0A004F11A0
    Kind Regards,
    Aidan H
    Applications Engineer
    National Instruments UK & Ireland

  • Remove a background from an image

    this seems so basic but I am just new to this and trying to create banners for my garden furniture websiteRemoving  . how do you remove the background from a lifestyle image so that the image looks like it is floating. thanks for your help.

    I Googled "photoshop mask."
    There are many tutorials out there. Here's one:
    http://designshack.net/articles/graphics/a-complete-beginners-guide-to-masking-in-photosho p

  • How do you remove the background from an image

    how do you remove the background from an image thathas a white background?

    First, change the background layer to a normal layer if needed, by dragging the padlock to the trash can.
    Then use the quick selection tool or magic wand tool to select your background.
    Now you can either delete the background, or click the icon at the bottom of the layers panel that looks like a circle inside a square. This icon will convert the selection to a mask.
    The advantage of the mask is, it is non-destructible. In that you can change your mind at any time. Whereas deleting pixels is permanent once you close the file and there is no duplicate files. (A way around this is to make a duplicate layer and hide it. But that does make the file larger.)

  • Vertical repeating background slice from image

    Hi. I'm trying to slice a portion of a Photoshop CS4 image and use it as a vertical repeating background at the top of a web page. Then I'm overlaying the full image in the horizontal center of the web page. No matter how much I try, the background slice image comes out a little washed out compared to the full image -- with a slight border to each slice.
    What am I doing wrong? I've tried saving the image slice as GIF, JPG, and PNG, but they all produce the same result. Thanks.

    I had the slice set to 2px wide. Once I zoomed in very close, I could see that the right pixel was lighter than the left one all the way down the slice. I had feather set to 0 and it still did this. I sliced it down to 1px and that fixed it.

  • Urgent : how to put an image into database and how to get it from it?

    hi,
    in the database i made a longblob type for image, and in my java code i have the path of the image (String): "C:\............." and i want to put this image in my data base.
    also i want to know how to get the image after put it in the database.
    please help me, it's so urgent.

    This is a way of getting the image out of the database.
    class yourClass{
    private byte[] buff;
    private ByteArrayOutputStream byteArrayOutputStream;
    public yourClass()
    Statement statement = connection.createStatement(ResultSet.TYPE_SCROLL_INSENSITIVE, ResultSet.CONCUR_READ_ONLY);
    ResultSet result = statement.executeQuery("your query");
    while ( result.next()){
    try{
    BufferedInputStream bin = new BufferedInputStream(rs.getBinaryStream("imagecolumn"));
    byteArrayOutputStream = new ByteArrayOutputStream();
    int length = bin.available();
    buff = new byte[length];
    while ( bin.read( buff, 0, length ) != -1 ) {
    byteArrayOutputStream.write( buff, 0, length );
    bin.close();
    catch(Exception e){
    The class about is used to take the image out of the database and store it in an object which is then streamed out through a servlet to display on the jsp page.
    import javax.servlet.*;
    import javax.servlet.http.*;
    import java.io.*;
    import java.util.*;
    import java.sql.*;
    public class ImageServlet extends HttpServlet {
    public void init() throws ServletException {    }
    public void destroy() {    }
    protected void doGet(HttpServletRequest request, HttpServletResponse response)
    throws ServletException, IOException {
    try
    yourClass pro = (yourClass)request.getSession().getAttribute("object");
    while ( iterator.hasNext() ) {
    pro = ( Product ) iterator.next();
    response.setContentType("image/jpg");
    ByteArrayOutputStream byteArrayOutputStream = pro.getImage();
    response.setContentLength( byteArrayOutputStream.size() );
    response.getOutputStream().write( byteArrayOutputStream.toByteArray() );
    response.getOutputStream().flush();
    return;
    catch (Exception e)
    e.printStackTrace();
    throw new ServletException(e);
    protected void doPost(HttpServletRequest request, HttpServletResponse response)
    throws ServletException, IOException {
    doGet(request, response);
    This is a little messy but if you search the forums you will find out more on it. Search for Images and database.

  • How to place an image in database and how to retrieve and display it in the front end

    how to place an image in database and how to retrieve and display it in the front end
    and to place an image in database and retrieve the image from database using xml
    please,help me out.

    Create a table with a Long RAW Datatype column for storing the Image Column Data.
    Create the form based on the table , which by defaults the column with LONG RAW atatype to a Image Item.
    You can use Forms Built in function READ_IMAGE_FILE to read a Image file stored on the file system in to the image item.
    A save on the form saves the image in the Image item in the long raw column.

  • Saving images into database

    Hi All,
    I have a table with 3 BLOB columns to store images and a NUMBER type column to store the image id_no. I am using database 10g and Forms 6i
    My problem is I recently updated the database from 8i to 10g, and since then I am unable to update or insert the new images in these BLOB columns. When I update the existing image or insert new image record through forms, It does save the changes in existing or new record. But It does not show these images while query the record. and also does not give any error while executing the query in forms.
    But while trying to retrive the image from updated records or new record in reports, It throughs the error that image is format is unreadable or currupt.
    There wasn't any problem in 8i, i could update the record as many times I wanted or create as many records as needed.
    Is anybody have any clue about this problem! Any help in this regard will be highly appriciated.
    Thanking you and Best Regards.

    You should not save an image to database, since it'll make database slow, and difficult to write a web page to load image.
    Save an image to specific location, and save image location to database.
    Then, use <img> tag to call an image in web page.

Maybe you are looking for