Image upload through Portals?

Hi All,
I have a image field in my table and integrated with portals...I can able to see the existed images in the iviews, but I can't able to upload a image from portals.
I didn't find any attachment button next to image value, please let me know how can I can add images through portals...
Regards,
Pooja

This seems odd.... don't you get any options as to enable the image upload? Try looking at the iview properties, as where you set up the size, heigth etc, instead of the options given on the iView wizard.
for instance, add the iview to a page. Open the page for edition and click on the iView to select it. Click on properties and on the right you should see them. Do you get anything useful there?
I am currently using SP04 but I assisted to the SP5 webex presentation, and is stated there that this feature is in place
Regards
Alejandro

Similar Messages

  • Propagate Image Upload Across Portal Servers

    Hi,
    I'm trying to investigate the best way of propagating image uploads across portal landscape.
    We have a requirement where Partner's are able to upload their company logo, to be displayed in the masthead.
    I've managed to create an iview to upload and validate the image, but I need to find a mechanism to copy the image file to all portal servers.
    I have found other posts which recommend mapping a drive, but I don't want a single point of failure, also for performance reasons I don't really want to store images in database.
    Is there a mechanism to deploy to all servers?
    Thanks
    Jason.

    If you can make use of the Knowledge Management System to store your image, then you can set up Content Exchance using the ice_service to move images to different systems.
    Check out this link
    http://help.sap.com/saphelp_erp2005/helpdata/en/35/4cf72bfe18455e892fc53345f4f919/frameset.htm

  • Problem in Image uploading through a view -- URGENT

    Hii Experts,
    I am facing very strange problem while uploading a image file (.JPG file) thru a web dynpro view.
    I am accepting a image file from view and uploading it to a ftp server.
    There are two abnormal results I have observed. It does NOT  happen for every image upload. But it has been observed to happen during peak Internet hrs. (image size can range from 1MB to 7-8 MBs)
    When 'Upload' button is clicked, one of the following thing happens:-
    1.  After taking loooong time (processing circle rotates), browser screen goes totally blank. That is, browser goes into state as if no page is opened (white screen)
    2. After taking loooong time, empty form re-appears. ( ie the view in which i had submitted data and pressed 'Upload')
    I have tried tracing errors in default trace. but no error or exception is displayed !!!
    Following is the code i'm using for uploading file. ==>
    try {
    URL myUrl = new URL("ftp://<some address>");
    FtpURLConnection myConnection = new FtpURLConnection(myUrl);
    myConnection.connect();
    OutputStream out = myConnection.getOutputStream();
    out.write(wdContext.currentPhotosElement().getPhoto1());
    out.close();
    myConnection.close();
    } catch (Exception e) {
    System.err.println("\n\n$$$$$$$$$$$$$Exception in image upload $$$$$$$$$$$$$\n\n");
    e.printStackTrace();
    Please help me as this system is live and lot of users are complaining as they are not able to upload their images..
    Awaiting for reply ..
    regards,
    Amey
    Edited by: Amey Mogare on May 28, 2008 2:14 PM
    Edited by: Amey Mogare on May 28, 2008 2:17 PM

    In SE78 when we click on the graphics and then click on the BMAP ( Bitmap Images ) then the bdc is not cathcing the screen and its giving an error
    This is the error message which i am recieving in it .
    00 343 S Cursor field RSTXT-TDNAME . does not exist in the screen
    Please suggest me that is there any way for the same or else is there any BAPI for the same .
    Regards
    Shankar

  • Import Images through Portal

    Dear SDNers!!!!
    I have a requirement where portal users will upload images through Portal from there local machines. when I am trying to do so I am getting error as "illegal value parameter". I am able to assign images to records via portal if they are saved in MDM, but not able to upload through local machine. I tried the option of setting config parameter allow invalid parameter as yes, but still same error.
    Am I missing some settings which I have to do for this.
    Thanks in Advance
    Dilmit Kaur Chadha

    Hi Dilmit,
    which file format are you using to upload images for e.g. JPEG, BMP etc, in MDM console just right click on repository & choose properties and check below option properties
    Prohibit Photoshop images   "YES/No"
    Use only Photoshop for processing "YES/No"
    allow invalid images "YES/No"
    Note : for Prohibit Photoshop images if you set "YES" will not allowed to upload prohibited images
    Hope above option may resolved your problem
    Thanks,
    Jignesh Patel

  • Problem while uploading text file through portal into WebDAV repository .

    Hi all...
    I am not able to upload any file through portal onto my webDav repository for remote server however reverse is possible i.e. any document created at remote server is reflected in portal.
    Everytime when i try to upload file though portal , i get the following error::
    The item could not be created because an exception occurred in the framework.
    Kindly suggest what to do....
    ThankS

    Hi Chetna,
    Have you specified any user information in the webdav repository....Like always connect through this user, in the webdav repsository tab....This user may not have write permission in the windows.
    Also are you sure that the user you logged in portal by which you failed to create new files or folders and the user that was able to create file in the windows are one and the same.....
    Regards,
    Ganesh N

  • How can I upload a (image) file through an applet ?

    How can I upload a (image) file through an applet ?

    have a look at http://www.haller-systemservice.net/jupload/
    i'm using Apache Jakarta HTTPClient to create a new HTTP connection to the webserver and sending a new POST request, which holds the image file. (So it's RFC1867 conform)
    there is also an open source implementation of such an applet on sourceforge. it's also called JUpload, but i think it's not maintained any more.

  • How do I add image upload to web app edit template?

    How do I add image upload to web app edit template. When creating fields I am selecting image from the field type. But the only way to upload and image is when I create the web app item within the admin. The option to upload an image is not available when the user submit web form opens.
    Wont send any of these questions through this email anymore but really needed assistance.
    Thanks,
    Gordon

    On the Details tab of the Web App setup, under Web App Item Options; have you ticked "Allow File Upload" and specified a Default Upload Folder?

  • How do I display blob (image) in a Portal Report

    I am using 9ias 10222 and portal 30983 and I have a table that stores an image as a blob and have a varchar field to store the mime type. I have created a form to upload the image and can then query the form to display the image.
    How do I dislay the image in a Portal Report/Dynamic Page Component. I have followed note 68016.1 but the retrieve_img_data procedure does not work it gives a wwv-11230 error.
    Any ideas? Any help would be appreciated.
    Thanks
    Belinda

    Hi,
    Can you display what code you used for this? I followed note 172045.1 and everything compiles properly but when I run the report, I just get a box with a red X in it, like it is not finding the picture. I ran the procedure that downloads the image and it works fine from there. Thanks.

  • ZCM 11.2.3a Image upload error [directory does not exist]

    We are uploading a number of images to the server.
    A lot of these are large images and the workstation has been build as a VMWare workstation.
    So far with the exception of one, all have uploaded successfully.
    One image is failing to upload when it is about halfway through. The error displayed on the workstation says "Directory not found"
    Looking at the novell-pbserv.log I see the following error message related to the image upload.
    RWCC unknown compression command code: 0x4000000 (67108864)
    RIP2 RWCC faiolure 3, 1851,
    Any help /ideas appreciated.
    Thanks
    Mark

    Hi Shaun,
    No we are using the the ZCM 11.2 pxe boot files.
    Although we have upgraded to ZCM 11.2.3a the image files from 11.2.3.a and the latest October Imaging update are crashing.
    I did post on the forums regards this and have a SR open for it. # 10865188291
    We are testing an upload of this particular image for the 3rd time. The other images have uploaded without issues.
    They have run a defrag on the disk prior to uploading.
    Regards
    Mark

  • Employee Photo Upload through binary data

    Hi all,
    I know the Provision for Photo upload through OAAD Tcode, I know FM to upload the photos by giving path as input data. my requirement is I have picture in the form of binary data . i want to upload that into PA30. I have return the following code. No Error but image is not displayed in PA30.Can u Please correct me?
    tables: toav0, toaom, twfdb, toapa.
    data: key like ojint-key,
          object like ojint-name,
          object_id like toav0-object_id,
          archiv_id like toav0-archiv_id,
          arc_doc_id like toav0-arc_doc_id,
          ablagedatum like sapb-sapabldate,
          ar_date like toav0-ar_date,
          del_date like toav0-del_date,
          sap_object like toaom-sap_object,
          ar_object like toaom-ar_object,
          expiry_tim like toaom-expiry_tim,
          method like ojint-method,
          return like ojint-return,
          parameter like ojint-parameter.
    data:begin of i_toav0 occurs 1.
            include structure toav0.
    data: end of i_toav0.
    data: begin of i_toaom occurs 1.
            include structure toaom.
    data: end of i_toaom.
    data: begin of fields occurs 1.
            include structure ojfields.
    data: end of fields.
    DATA:     filename1  TYPE string.
    Data: i_name TYPE STXBITMAPS-TDNAME value 'TEST',
    *  archiv_id like toav0-archiv_id,
    i_id TYPE STXBITMAPS-TDID VALUE 'BMAP',
    i_btype TYPE STXBITMAPS-TDBTYPE VALUE 'BCOL',
    l_bds_bytecnt TYPE i,
    FLENGTH TYPE SAPB-LENGTH,
    l_bds_content TYPE TABLE OF bapiconten,
    OUTDOC     LIKE     TOADT ,
    wa_l_bds_content TYPE  bapiconten.
    *DATA : BINARY TYPE STANDARD TABLE OF TBL1024,
    data : BINARY TYPE STANDARD TABLE OF TBL1024 WITH HEADER LINE,
    ARCHIVOBJECT type standard table of docs,
    archiv_doc_id like toav0-arc_doc_id,
    wa_binary type TBL1024.
    data:  lw_ar_object like toaom-ar_object,
          lw_object_id like sapb-sapobjid,
          lw_sap_object like toaom-sap_object,
          lw_doc_type like toadd-doc_type,
          lw_path like sapb-sappfad,"toav0-arc_doc_id
    *      archiv_doc_id like toav0-arc_doc_id,
          doc_type like toadt-doc_class.
    constants:  c_sap_object type toaom-sap_object value 'PREL',
                c_ar_object type toaom-ar_object value 'HRICOLFOTO',
                c_doc_type type toaom-doc_type value 'JPG'.
    PARAMETERS: filename(150) TYPE c OBLIGATORY.                               "Name of the File where source as  txt format
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR filename.
      PERFORM getfile.
    start-of-selection.
      filename1 = filename.
    key = '010001380002'.
      lw_ar_object = c_ar_object.
    *  lw_object_id = w_pernr_pass.
      lw_sap_object = c_sap_object.
      lw_doc_type = c_doc_type.
    *  lw_path = it_data-file_nam.
      CALL FUNCTION 'GUI_UPLOAD'
        EXPORTING
          filename = filename1
          filetype = 'BIN'
        TABLES
          data_tab = archivobject.
    * Object to be archived
          select single * from toaom where ar_object = c_ar_object and sap_object = c_sap_object.
          if sy-subrc <> 0.
            raise UPLOAD_ERROR.
          else.
    * Authority check with Archive id
            archiv_id = toaom-archiv_id.
            perform authority_check_create(oaall)
            using archiv_id object space ar_object space
            changing sy-subrc.
            if sy-subrc ne 0.
              raise UPLOAD_ERROR.
            else.
              if sy-subrc <> 0.
                raise UPLOAD_ERROR.
                clear toav0.
              else." Transfer key for archiving
                toav0-object_id = key.
                if key eq space.
                  Raise FUNCTION_ERROR.
                  clear toav0.
                else.
                  perform create_archive_object_new  .
                endif.
              endif.
            endif.
          endif.
    form create_archive_object_new .
    CALL FUNCTION 'ARCHIV_CREATE_TABLE'
        EXPORTING
          AR_OBJECT                      = lw_ar_object
    *   DEL_DATE                       =
          OBJECT_ID                      = '010001380002'
          SAP_OBJECT                     =  lw_sap_object
    *   FLENGTH                        = '2328'
       DOC_TYPE                       = lw_doc_type
    *   DOCUMENT                       =
    *   MANDT                          = SY-MANDT
    * IMPORTING
    *   OUTDOC                         =
       TABLES
       ARCHIVOBJECT                   =  ARCHIVOBJECT
    *     BINARCHIVOBJECT                = binary
    * EXCEPTIONS
    *   ERROR_ARCHIV                   = 1
    *   ERROR_COMMUNICATIONTABLE       = 2
    *   ERROR_CONNECTIONTABLE          = 3
    *   ERROR_KERNEL                   = 4
    *   ERROR_PARAMETER                = 5
    *   ERROR_USER_EXIT                = 6
    *   ERROR_MANDANT                  = 7
    *   OTHERS                         = 8
      IF SY-SUBRC <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
      call function 'ARCHIVOBJECT_CREATE_TABLE'
        EXPORTING
          archiv_id                = archiv_id
          document_type            = lw_doc_type
    *      length                   = '2328'
        IMPORTING
          archiv_doc_id            = i_toav0-arc_doc_id
        TABLES
          archivobject             = archivobject
    *      binarchivobject          = BINARY
        EXCEPTIONS
          error_kernel             = 1
          error_communicationtable = 2
          error_archiv             = 3.
           move i_toav0 to toav0.
        toav0-sap_object = lw_sap_object.
        toav0-object_id = key.
        move archiv_id to toav0-archiv_id.
        move i_toav0-arc_doc_id to toav0-arc_doc_id.
        toav0-ar_object = lw_ar_object.
        move lw_doc_type to toav0-reserve.
        move lw_doc_type to doc_type.
        commit work.
      call function 'ARCHIV_CONNECTION_INSERT'
          exporting
            archiv_id                   = toav0-archiv_id
            arc_doc_id                  = toav0-arc_doc_id
            ar_date                     = ar_date
            ar_object                   = toav0-ar_object
    *     DEL_DATE                    = ' '
    *     MANDANT                     = ' '
            object_id                   = '010001380002'
            sap_object                  = toav0-sap_object
            doc_type                    = doc_type
    *        barcode                     = barcode
          exceptions
            error_connectiontable       = 1
            others                      = 2
    endform.
    FORM getfile .
      CALL FUNCTION 'WS_FILENAME_GET'
        EXPORTING
          def_filename     = ' '
          def_path         = '*.*'
          mask             = ''
          mode             = 'O'
          title            = ' SELECTING FILE FOR SOURCE PROGRAM'
        IMPORTING
          filename         = filename
        EXCEPTIONS
          selection_cancel = 3
          selection_error  = 4.

    Hi all,
    I know the Provision for Photo upload through OAAD Tcode, I know FM to upload the photos by giving path as input data. my requirement is I have picture in the form of binary data . i want to upload that into PA30. I have return the following code. No Error but image is not displayed in PA30.Can u Please correct me?
    tables: toav0, toaom, twfdb, toapa.
    data: key like ojint-key,
          object like ojint-name,
          object_id like toav0-object_id,
          archiv_id like toav0-archiv_id,
          arc_doc_id like toav0-arc_doc_id,
          ablagedatum like sapb-sapabldate,
          ar_date like toav0-ar_date,
          del_date like toav0-del_date,
          sap_object like toaom-sap_object,
          ar_object like toaom-ar_object,
          expiry_tim like toaom-expiry_tim,
          method like ojint-method,
          return like ojint-return,
          parameter like ojint-parameter.
    data:begin of i_toav0 occurs 1.
            include structure toav0.
    data: end of i_toav0.
    data: begin of i_toaom occurs 1.
            include structure toaom.
    data: end of i_toaom.
    data: begin of fields occurs 1.
            include structure ojfields.
    data: end of fields.
    DATA:     filename1  TYPE string.
    Data: i_name TYPE STXBITMAPS-TDNAME value 'TEST',
    *  archiv_id like toav0-archiv_id,
    i_id TYPE STXBITMAPS-TDID VALUE 'BMAP',
    i_btype TYPE STXBITMAPS-TDBTYPE VALUE 'BCOL',
    l_bds_bytecnt TYPE i,
    FLENGTH TYPE SAPB-LENGTH,
    l_bds_content TYPE TABLE OF bapiconten,
    OUTDOC     LIKE     TOADT ,
    wa_l_bds_content TYPE  bapiconten.
    *DATA : BINARY TYPE STANDARD TABLE OF TBL1024,
    data : BINARY TYPE STANDARD TABLE OF TBL1024 WITH HEADER LINE,
    ARCHIVOBJECT type standard table of docs,
    archiv_doc_id like toav0-arc_doc_id,
    wa_binary type TBL1024.
    data:  lw_ar_object like toaom-ar_object,
          lw_object_id like sapb-sapobjid,
          lw_sap_object like toaom-sap_object,
          lw_doc_type like toadd-doc_type,
          lw_path like sapb-sappfad,"toav0-arc_doc_id
    *      archiv_doc_id like toav0-arc_doc_id,
          doc_type like toadt-doc_class.
    constants:  c_sap_object type toaom-sap_object value 'PREL',
                c_ar_object type toaom-ar_object value 'HRICOLFOTO',
                c_doc_type type toaom-doc_type value 'JPG'.
    PARAMETERS: filename(150) TYPE c OBLIGATORY.                               "Name of the File where source as  txt format
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR filename.
      PERFORM getfile.
    start-of-selection.
      filename1 = filename.
    key = '010001380002'.
      lw_ar_object = c_ar_object.
    *  lw_object_id = w_pernr_pass.
      lw_sap_object = c_sap_object.
      lw_doc_type = c_doc_type.
    *  lw_path = it_data-file_nam.
      CALL FUNCTION 'GUI_UPLOAD'
        EXPORTING
          filename = filename1
          filetype = 'BIN'
        TABLES
          data_tab = archivobject.
    * Object to be archived
          select single * from toaom where ar_object = c_ar_object and sap_object = c_sap_object.
          if sy-subrc <> 0.
            raise UPLOAD_ERROR.
          else.
    * Authority check with Archive id
            archiv_id = toaom-archiv_id.
            perform authority_check_create(oaall)
            using archiv_id object space ar_object space
            changing sy-subrc.
            if sy-subrc ne 0.
              raise UPLOAD_ERROR.
            else.
              if sy-subrc <> 0.
                raise UPLOAD_ERROR.
                clear toav0.
              else." Transfer key for archiving
                toav0-object_id = key.
                if key eq space.
                  Raise FUNCTION_ERROR.
                  clear toav0.
                else.
                  perform create_archive_object_new  .
                endif.
              endif.
            endif.
          endif.
    form create_archive_object_new .
    CALL FUNCTION 'ARCHIV_CREATE_TABLE'
        EXPORTING
          AR_OBJECT                      = lw_ar_object
    *   DEL_DATE                       =
          OBJECT_ID                      = '010001380002'
          SAP_OBJECT                     =  lw_sap_object
    *   FLENGTH                        = '2328'
       DOC_TYPE                       = lw_doc_type
    *   DOCUMENT                       =
    *   MANDT                          = SY-MANDT
    * IMPORTING
    *   OUTDOC                         =
       TABLES
       ARCHIVOBJECT                   =  ARCHIVOBJECT
    *     BINARCHIVOBJECT                = binary
    * EXCEPTIONS
    *   ERROR_ARCHIV                   = 1
    *   ERROR_COMMUNICATIONTABLE       = 2
    *   ERROR_CONNECTIONTABLE          = 3
    *   ERROR_KERNEL                   = 4
    *   ERROR_PARAMETER                = 5
    *   ERROR_USER_EXIT                = 6
    *   ERROR_MANDANT                  = 7
    *   OTHERS                         = 8
      IF SY-SUBRC <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
      call function 'ARCHIVOBJECT_CREATE_TABLE'
        EXPORTING
          archiv_id                = archiv_id
          document_type            = lw_doc_type
    *      length                   = '2328'
        IMPORTING
          archiv_doc_id            = i_toav0-arc_doc_id
        TABLES
          archivobject             = archivobject
    *      binarchivobject          = BINARY
        EXCEPTIONS
          error_kernel             = 1
          error_communicationtable = 2
          error_archiv             = 3.
           move i_toav0 to toav0.
        toav0-sap_object = lw_sap_object.
        toav0-object_id = key.
        move archiv_id to toav0-archiv_id.
        move i_toav0-arc_doc_id to toav0-arc_doc_id.
        toav0-ar_object = lw_ar_object.
        move lw_doc_type to toav0-reserve.
        move lw_doc_type to doc_type.
        commit work.
      call function 'ARCHIV_CONNECTION_INSERT'
          exporting
            archiv_id                   = toav0-archiv_id
            arc_doc_id                  = toav0-arc_doc_id
            ar_date                     = ar_date
            ar_object                   = toav0-ar_object
    *     DEL_DATE                    = ' '
    *     MANDANT                     = ' '
            object_id                   = '010001380002'
            sap_object                  = toav0-sap_object
            doc_type                    = doc_type
    *        barcode                     = barcode
          exceptions
            error_connectiontable       = 1
            others                      = 2
    endform.
    FORM getfile .
      CALL FUNCTION 'WS_FILENAME_GET'
        EXPORTING
          def_filename     = ' '
          def_path         = '*.*'
          mask             = ''
          mode             = 'O'
          title            = ' SELECTING FILE FOR SOURCE PROGRAM'
        IMPORTING
          filename         = filename
        EXCEPTIONS
          selection_cancel = 3
          selection_error  = 4.

  • Uploading a Portal resource to Spaces

    Version: WebCenter 11g PS3 (Spaces)
    Hi,
    I have created a custom page template in JDeveloper using the DesignWebCenterSpaces.jws workspace. ( I am refering the Chapter 49 of WebCenter Developer Guide).
    In the page temaplate I have included some task flows and some images. Now to upload this page template to WebCenter Spaces, what should I do ?
    I could find that there is an option "Upload a Portal Resource". Can this option be used to upload the page template I have created (with task flows and images). I am wondering How will the images and TF's will be uploaded to Spaces ? Please can someone clarify my thoughts ?

    Hi,
    Beside 'Upload a Portal Resource' there is an option for Export Portal Resource, use that option and export the page template as an EAR file.
    Than take that EAR file and upload it under Resources > Page Template in Administration (Home Space), So that the template would be available to all Spaces.
    For Taskflows, you can do the same thing. Or we have used the SampleWebCenterExtensions project available from: http://www.oracle.com/technetwork/middleware/webcenter/white-papers-088385.html, and Desploy a Shared Library with our custom Taskflows so that all customizations will be deployed together.
    There is a public folder under SampleWebCenterExtensions > SourceFiles > public_html > web > oracle > webcenter > webcenterapp > view > templates > publichtml, in which you can save images and other custom jsp files and can call from the path: http://<domain-name>/webcenter/oracle/webcenter/webcenterapp/view/templates/publichtml/ ...
    Hopefully, it makes sense :)
    Best Regards.

  • Fetch Graphic Image uploaded in QM01 into smartforms.

    Hi All,
    Is there any way to fetch Grpahic images uploaded in QM01 Transaction Code and display the same in smartforms.
    Note: Images are Uploaded while creating Notification through QM01 Tcode by clicking SERVICES FOR OBJECTS--> CREATE -->CREATE ATTACHMENT  on left side of title bar_CREATE NOTIFICATION: COMPLAINT AG.VENDOR_
    Regards,
    Nagesh.

    There are many threads/documents about that, search for SO_DOCUMENT_READ_API1 for example.
    But first of all, read Note 927407 - Determining the content of GOS and SAPoffice documents

  • Image upload safari ios6 issue -file name always image.jpg

    I could not wait for ios6 when I found out safari allowed for image / photo upload through safari web forms.
    I tested and see the image in form..hit submit and it uploads with the file name image.jpg
    Do it again and same file name for a different photo. This is completely useless. If I upload to my website it just overwrites. 99% of the masses need a unique name, when uploading. Why can it now use the file name in the photos folder?
    Even emailing them out it holds a generic name.
    Looks like an easy fix...insert file name not default name. Lets fix this Apple..or your new feature is as worthless as not having it at all.
    Disappointed to say the least...no I am dumbfounded.

    @kdmasterdas: How did you rename the file??
    It really *** that Apple is not fixing this problem while it's a big problem, especially in a business environment.

  • Image upload bombs

    I'm working through a book right now on PHP, MySQL, and Web
    Dev. For the most part I've been doing fine, but when I was
    creating an image upload form today, it's giving me some errors.
    Here's the url:
    http://lwrussell.com/phptesting/chapt7/upload_image.htm
    Here's my form:
    <html>
    <head>
    <title>Upload your pic to our site!</title>
    </head>
    <body>
    <form name="form1" method="post" action="check_image.php"
    enctype="multipart/form-data">
    <table border="0" cellpadding="5">
    <tr>
    <td>Image Title or Caption<br>
    <em>Example: You talkin' to me?</em></td>
    <td><input name="image_caption" type="text"
    id="item_caption" size="55"
    maxlength="255"></td>
    </tr>
    <tr>
    <td>Your Username</td>
    <td><input name="image_username" type="text"
    id="image_username" size="15"
    maxlength="255"></td>
    </tr>
    <td>Upload Image:</td>
    <td><input name="image_filename" type="file"
    id="image_filename"></td>
    </tr>
    </table>
    <br>
    <em>Acceptable image formats include: GIF, JPG/JPEG,
    and PNG.</em>
    <p align="center"><input type="submit" name="Submit"
    value="Submit">
    <input type="reset" name="Submit2" value="Clear Form">
    </p>
    </form>
    </body>
    </html>
    Here's my php code:
    <?php
    //connect to the database
    $link = mysql_connect("hostomitted", "usernameomitted",
    "passwordomitted")
    or die("Could not connect: " . mysql_error());
    mysql_select_db('moviesite', $link)
    or die(mysql_error());
    //make variables available
    $image_caption = $_POST['image_caption'];
    $image_username = $_POST['image_username'];
    $image_tempname = $_FILES['image_filename']['name'];
    $today = date("Y-m-d");
    //upload image and check for image type
    //make sure to change your path to match your images
    directory
    $ImageDir ="
    http://lwrussell.com/phptesting/chapt7/images/";
    $ImageName = $ImageDir . $image_tempname;
    if (move_uploaded_file($_FILES['image_filename']['tmp_name'],
    $ImageName)) {
    //get info about the image being uploaded
    list($width, $height, $type, $attr) =
    getimagesize($ImageName);
    switch ($type) {
    case 1:
    $ext = ".gif";
    break;
    case 2:
    $ext = ".jpg";
    break;
    case 3:
    $ext = ".png";
    break;
    default:
    echo "Sorry, but the file you uploaded was not a GIF, JPG,
    or " .
    "PNG file.<br>";
    echo "Please hit your browser's 'back' button and try
    again.";
    //insert info into image table
    $insert = "INSERT INTO images
    (image_caption, image_username, image_date)
    VALUES
    ('$image_caption', '$image_username', '$today')";
    $insertresults = mysql_query($insert)
    or die(mysql_error());
    $lastpicid = mysql_insert_id();
    $newfilename = $ImageDir . $lastpicid . $ext;
    rename($ImageName, $newfilename);
    ?>
    <html>
    <head>
    <title>Here is your pic!</title>
    </head>
    <body>
    <h1>So how does it feel to be
    famous?</h1><br><br>
    <p>Here is the picture you just uploaded to our
    servers:</p>
    <img src="images/<?php echo $lastpicid . $ext; ?>"
    align="left">
    <strong><?php echo $image_name;
    ?></strong><br>
    This image is a <?php echo $ext; ?> image.<br>
    It is <?php echo $width; ?> pixels wide
    and <?php echo $height; ?> pixels high.<br>
    It was uploaded on <?php echo $today; ?>.
    </body>
    </html>
    Thanks guys! I appreciate it.
    -Luke

    Never mind, I figured it out. The $ImageDir needed so simply
    be "images/"

  • Uploaded through Bridge CC photos from my camera; went through the motions, not paying attention, bu

    Uploaded through Bridge CC photos from my camera; went through the motions, not paying attention, but it did NOT save 'em where I usually save 'em; how can I ask Brindge or just the Mac Finder the last files I downloaded & where I saved 'em too? Oh, yeah, it ERASED the photos from my camera. I basically just need to ask my Mac (OS 10.8) where I downloaded 'em to. Thanks!

    Uploaded through Bridge CC photos from my camera; went through the motions, not paying attention,
    I'm not sure I do follow this, what do you mean with motions? can you specify this?. I assume you used Photodownloader? BTW, Not paying attention is usually not the best way when importing images...
    but it did NOT save 'em where I usually save 'em; how can I ask Brindge or just the Mac Finder the last files I downloaded & where I saved 'em too?
    When you import files they are written to your disk and therefor no need for save them, the files are already at your disk or written to the location you choose as destination. You could select your computername in the navigation column and then use the list view and choose the column last modified but this is not always showing the correct result. You could also do a spotlight search (or use the free Easy Find you can download from Devon) and choose to search for the extension you have shot your files in (Raw, jpeg??) and then choose modification date to sort.
    There is not a log (at least not to my knowledge) that keeps track of all of your movements unless you have installed such application (don't know if there is one but I think there will be a thrid party or script written by someone). You could try Console (in the utilities folder) that holds your logs and reports but this is usually for crash or forced quit situations.
    Oh, yeah, it ERASED the photos from my camera. I basically just need to ask my Mac (OS 10.8) where I downloaded 'em to. Thanks!
    Well, this would mean you would have first select the option to do so in Photodownloader. While I use PDL on a daily base I always thought this option should not even be present to choose and you certainly should not use it to delete originals.
    Like Curt already stated you have to use the camera software for this with the card in the camera. Either delete but preferable format the card. Mind you, this should not be done before you are sure where your files are written to and after you have checked randomly to see if the previews have build correctly for the newly imported files. Then you should make a back up of those files and only then start thinking about erasing or formatting the card for new use.
    If you have not done very strange things (like choosing the card as destination but if so they might still be there- check finder in column mode- or wrote them to an external disk - where they also still should be) the files should be somewhere at your system. Just do an extensive search and if the files are really important check for recovering software for your card.
    And follow the steps described above for importing, sometimes we need to learn our lessons the hard way (and I have been there too...)

Maybe you are looking for

  • Bigbang Xpower wont boot

    Hi, First I'm sorry if my english is kinda bad. I just installed motherboard, RAM and CPU because my previous PC wont boot either. The problem is the same. When I turn it on my PC wont boot. Tried to disconnect all the harddrive, change the VGA, put

  • Captions apparently broken in Aperture 3.3.2

    I'm running Aperture 3.3.2 on Mountain Lion, and it appears that Aperture isn't writing captions to the IPTC field when exporting images.

  • RFE: Column filtering should allow wild card and list.

    Request for enhancement:- if user enter value1, value2, value3 in filter please convert it SQL expression as field_name like 'value1' or field_name like 'value2' or field_name like 'value3' also allow a way in GUI to select multiple item in the filte

  • Fiedl Validation for Warning Message not for Error Message

    hi all, we know for field validation, once it not meet the validation, it will throw out the error message and don't allow you to save the record. But is there any way to show warning message just a note then user can continue the operation? Thanks A

  • IMac OSX  Kernal Errors

    Hello; My imac over the past week or so has restarted itself with the error message stating I have to restart my imac. I have saved two of the Kernal messages forwarded to Apple.  Can anyone explain where the problem originates please.  I understand