Advertisement:

Author Topic: Tip: Add an upload status indicator on the item post/edit pages  (Read 15614 times)

RajaSekar

  • Hero Member
  • *****
  • Posts: 791
  • ராஜசேகர்
Re: Tip: Add an upload status indicator on the item post/edit pages
« Reply #15 on: February 27, 2012, 09:10:47 am »
Hi Raja,

Please enlighten me on this plugin,
Is it proposal to work on this plugin or did your forget to add files to appear in Admin panel like Help and  "<?php ajax _loader(); ?>" code?

regards

@ingo

you don't need to do anything only install the plugin

progress bar appear on when posting an ad and editing an ad

ingo

  • Full Member
  • ***
  • Posts: 216
Re: Tip: Add an upload status indicator on the item post/edit pages
« Reply #16 on: February 27, 2012, 10:26:38 am »
@RajaSekar

Thanks Raj,

It was not working in my script so I  thought there is problem with plugin, but  it was my coding fault in main script.

Thanks again for this Plugin  :)

mrreference

  • Jr. Member
  • **
  • Posts: 74
Re: Tip: Add an upload status indicator on the item post/edit pages
« Reply #17 on: November 24, 2012, 05:51:39 pm »
Hi, I have uploaded this script (zipped file) into manage plugins but it doesn't appear in list, any ideas?

snirpidotcom

  • Full Member
  • ***
  • Posts: 107
Re: Tip: Add an upload status indicator on the item post/edit pages
« Reply #18 on: December 07, 2012, 12:22:35 am »
mrreference

It have double folder, check this...

Legion

  • Hero Member
  • *****
  • Posts: 622
  • I am founder of top20remedies.com buyeradvise.com
Re: Tip: Add an upload status indicator on the item post/edit pages
« Reply #19 on: December 08, 2012, 11:53:09 pm »
it does not show in admin why?

snirpidotcom

  • Full Member
  • ***
  • Posts: 107
Re: Tip: Add an upload status indicator on the item post/edit pages
« Reply #20 on: December 09, 2012, 01:13:29 am »
mrreference an legion

It have double folder, check this...

snirpidotcom

  • Full Member
  • ***
  • Posts: 107
Re: Tip: Add an upload status indicator on the item post/edit pages
« Reply #21 on: December 09, 2012, 01:14:21 am »
when unzip is unzipped double folder...

texthiller

  • Full Member
  • ***
  • Posts: 207
Re: Tip: Add an upload status indicator on the item post/edit pages
« Reply #22 on: December 10, 2012, 12:14:43 pm »
Really fantastic!

Optimus

  • Jr. Member
  • **
  • Posts: 90
Re: Tip: Add an upload status indicator on the item post/edit pages
« Reply #23 on: January 19, 2013, 01:37:20 am »
Hello, I have installed the plugin but could not make it work, when I click on submit the status bar does not show. If i change the function from hidden to visible I can see the image so it is well installed and hooked, but submit would not make it display. Any idea ? Thanks.

asiatws

  • Newbie
  • *
  • Posts: 4
Re: Tip: Add an upload status indicator on the item post/edit pages
« Reply #24 on: January 19, 2013, 12:00:31 pm »
check plugin GIF Image path

Aficionado

  • Guest
Re: Tip: Add an upload status indicator on the item post/edit pages
« Reply #25 on: March 25, 2013, 06:21:44 pm »
The Ajax loader plugin has a problem.

When you Publish (and the animation starts) IF an error appears (short description for example) and you are asked to change it (doesn't save the ad), the animation keeps showing.

I think the code of the loader should change and show the animation if no errors and when the saving starts.

Thanks

onaldo

  • Jr. Member
  • **
  • Posts: 75
Re: Tip: Add an upload status indicator on the item post/edit pages
« Reply #26 on: April 06, 2013, 06:21:44 am »
It seems not working in item edit. I tried editing an item and adding a photo. The photo was not added. The item even disappeared at first.

It's working fine in item-add

Adolescent

  • Newbie
  • *
  • Posts: 8
Re: Tip: Add an upload status indicator on the item post/edit pages
« Reply #27 on: September 24, 2013, 01:54:13 am »
The Ajax loader plugin has a problem.

When you Publish (and the animation starts) IF an error appears (short description for example) and you are asked to change it (doesn't save the ad), the animation keeps showing.

I think the code of the loader should change and show the animation if no errors and when the saving starts.

Thanks

I had the same thought and so have solved this problem ;)


just change

Code: [Select]
<script type="text/javascript">
    function loadSubmit() {
var selected = $("#catId").val();
if(selected>0) {
var ProgressImage = document.getElementById('progress_image');
document.getElementById("progress").style.visibility = "visible";
setTimeout(function(){ProgressImage.src = ProgressImage.src},100);
return true;
}
    }
</script>

to:

Code: [Select]
<script type="text/javascript">
    function loadSubmit() {
var selected = $("#catId").val();
var error_msg = document.getElementById("error_list");
var validation_error = error_msg.hasChildNodes();
if((selected>0) && (validation_error == true)) {
var ProgressImage = document.getElementById('progress_image');
document.getElementById("progress").style.visibility = "visible";
setTimeout(function(){ProgressImage.src = ProgressImage.src},100);
return true;
}
    }
</script>


My code checks if the error_list has any child elements (errors) and consequently the status upload image is only displayed when there are NO errors msg.

Hope it helps.

Cheers
« Last Edit: September 24, 2013, 01:57:29 am by Adolescent »

heman85

  • Jr. Member
  • **
  • Posts: 98
Re: Tip: Add an upload status indicator on the item post/edit pages
« Reply #28 on: October 01, 2013, 07:57:02 am »
Work for me PERFECT. Thanks


Got Status?


Hi all,

For anyone interested in adding a simple "status" indicator to the Item Post or Item Edit pages, I'll show you a way to do so. This is not a "progress" indicator in the sense that it lets you know how far along the upload is. Rather, it simply gives a visual indication to the user that something is happening. You can use any animated GIF image you'd like with this... I'll show you where to get some.


Step 1: Edit your item-post.php or item-edit.php page (or both). Within the <head> section, at this code:
Code: [Select]
<script type="text/javascript">
    function loadSubmit() {
var selected = $("#catId").val();
if(selected>0){
    var ProgressImage = document.getElementById('progress_image');
    document.getElementById("progress").style.visibility = "visible";
    setTimeout(function(){ProgressImage.src = ProgressImage.src},100);
    return true;
}
    }
</script>


Step 2: Find this code near the bottom of the document:
Code: [Select]
<button type="submit">
Replace it with this code:
Code: [Select]
<button type="submit" onclick="return loadSubmit()" >

Step 3: Finally, place this code where you wish for the indicators to be seen (I suggest placing it immediately below the <button> code shown in Step 2):
Code: [Select]
<p style="visibility:hidden;" id="progress"/><img id="progress_image" style="padding-left:5px;padding-top:5px;" src="statusbar.gif" alt=""> Uploading in progress...</p>

You'll want to replace the image src statusbar.gif with the correct file path and name for your own image. The text, "Uploading in progress", can also be customized as you'd like.


Where to get your own animated GIF indicators:


Below, I've attached some images. The first one is of the "Publish" button before clicking it. The second image shows the status bar being displayed after clicking the "Publish" button.


Code source: http://www.ryantetek.com/2009/06/animated-progress-loading-bar-upon-form-submit-javascript/

Aficionado

  • Guest
Re: Tip: Add an upload status indicator on the item post/edit pages
« Reply #29 on: October 12, 2013, 01:04:38 am »
Hello.

Sorry to say that your below code change (with the error handling) doesn't work at all.

After the code change no image is displayed or message. Ever.



The Ajax loader plugin has a problem.

When you Publish (and the animation starts) IF an error appears (short description for example) and you are asked to change it (doesn't save the ad), the animation keeps showing.

I think the code of the loader should change and show the animation if no errors and when the saving starts.

Thanks

I had the same thought and so have solved this problem ;)


just change

Code: [Select]
<script type="text/javascript">
    function loadSubmit() {
var selected = $("#catId").val();
if(selected>0) {
var ProgressImage = document.getElementById('progress_image');
document.getElementById("progress").style.visibility = "visible";
setTimeout(function(){ProgressImage.src = ProgressImage.src},100);
return true;
}
    }
</script>

to:

Code: [Select]
<script type="text/javascript">
    function loadSubmit() {
var selected = $("#catId").val();
var error_msg = document.getElementById("error_list");
var validation_error = error_msg.hasChildNodes();
if((selected>0) && (validation_error == true)) {
var ProgressImage = document.getElementById('progress_image');
document.getElementById("progress").style.visibility = "visible";
setTimeout(function(){ProgressImage.src = ProgressImage.src},100);
return true;
}
    }
</script>


My code checks if the error_list has any child elements (errors) and consequently the status upload image is only displayed when there are NO errors msg.

Hope it helps.

Cheers
« Last Edit: October 12, 2013, 02:21:46 pm by Aficionado »