Jump to content

Search the Community

Showing results for tags 'images'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Welcome to PHP Freaks
    • Announcements
    • Introductions
  • PHP Coding
    • PHP Coding Help
    • Regex Help
    • Third Party Scripts
    • FAQ/Code Snippet Repository
  • SQL / Database
    • MySQL Help
    • PostgreSQL
    • Microsoft SQL - MSSQL
    • Other RDBMS and SQL dialects
  • Client Side
    • HTML Help
    • CSS Help
    • Javascript Help
    • Other
  • Applications and Frameworks
    • Applications
    • Frameworks
    • Other Libraries
  • Web Server Administration
    • PHP Installation and Configuration
    • Linux
    • Apache HTTP Server
    • Microsoft IIS
    • Other Web Server Software
  • Other
    • Application Design
    • Other Programming Languages
    • Editor Help (Dreamweaver, Zend, etc)
    • Website Critique
    • Beta Test Your Stuff!
  • Freelance, Contracts, Employment, etc.
    • Services Offered
    • Job Offerings
  • General Discussion
    • PHPFreaks.com Website Feedback
    • Miscellaneous

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Age


Donation Link

Found 3 results

  1. Hi I have a script for displaying images see below <?php include "header.php"; require 'gallery/Gallery.php'; ?> <?php $models=file("models.txt", FILE_USE_INCLUDE_PATH); if(isset($_POST['model'])){ $model=($_POST['model']); } $gallery = new Gallery(); $gallery->setPath('gallery/images/'.$model); $images = $gallery->getImages(array('jpg')); ?> <div class="container"> <?php if($images): ?> <div class=gallery cf > <?php foreach($images as $image):?> <div class="gallery-item"> <a href="<?php echo $image['full'];?>"><img src="<?php echo $image['thumb']; ?>"> </div> <?php endforeach; ?> </div> <?php else: ?> There are no images <?php endif; ?> </div> <div class="form"> <form action="index.php" method="POST"> <select name="model" class="select_box" data-placeholder="Select Model" style= width:120px;/> <option></option> <?php foreach($models as $mod):?> <option><?php echo $mod ?></option> <?php endforeach;?> </select> <input type="submit" Value="Select" value="Select"> </form> </div> <script type="text/javascript"> $(".select_box").chosen(); </script> The above code works , i get no errors this images array is populated at this line "$images = $gallery->getImages(array('jpg'));" but they do no show in the container class. When I run this script all the css shows borders and the like. bet there are no images didplayed. However it does work if I replace the code in the container class with this $images = "gallery/images/".$model; $files = scandir($images); unset($files[0], $files[1]); $rows = array_chunk($files, 6); foreach ($rows as $row){ foreach ($row as $image){ echo '<td><a href="gallery/images/', $model,'/', $image,'"><img src="gallery/images/',$model,'/thumbs/',$image,'"/></a></td>'; } } Is it possible I have a conflict with the jQuery. I am using the plugin called "chosen" The $models is a text file that populates the drop down box Thank you, your help is very much appreciated
  2. I am using this script for image uploads. https://www.w3schools.com/php/php_file_upload.asp I noticed that with some of the image uploads, I would get the error "Sorry, only JPG, JPEG, PNG & GIF files are allowed." The images i upload are one of the file types listed above. So I am wondering why i would get an error for some images but not others despite all them of being the same file types? Can you tell why judging from the script?
  3. Hi all and Guru Jacques, I have just ported my application on the VM server and the application seems to be working fine except that it does not display the images. The parallel application on my localhost on windows works fine. The two are same except for some changes in the path. I have checked that the paths are correct by using small test files that echo their file names telling me exactly which all paths have been successfully traversed by the app. On logging in, there is a graph which is normally displayed if there is corresponding data for the user. No matter how much I try I am unable to get that graph to print. So i simply placed an image in the folder and tried to invoke that instead but that too to no avail. The corresponding graph and image on the local host on windows works great. No issues there. My error.log and access.log on the VM have no errors recorded in them. They were recording errors just fine when there were a few errors while I was adjusting the path. I got the "unable to find so and so file errors which were successfully recorded. The point is that the application is not giving an errors. Not even the file not found ones. So I guess my path is correct. Here is the structure of the application with some names changed. docroot is the Document Root. aboveroot is a folder outside the root. The code for graph lies in this folder ( aboveroot/images). Since the graph did not display, I added an image here (images) for testing. That did not display either. index.php required invoke.php which invokes graph.php and should display the graph provided the user data exists. ---www |--- docroot |----- index.php |--- aboveroot |----images |-----invoke.php |----graph.php |---- abc.jpg |----test.php I then added a test.php : $file = '21.jpg'; echo '<img src = 21.jpg>'; echo "Found Test"; and called test.php from invoke.php instead of graph.php. While it echoed "Found Test", it did not display the image. The same code in localhost on windows displays the image with test.php and the graph with graph.php when invoked from So I am at a loss and looking for some help. Thanks all !
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.