Download history
-
Hey,
I want to make a download history to see who’s downloading files.
I’m trying to use the [stataway] shortcode but when i try to download a file it’s not showing in the table.
[fileaway type=”table” base=”uploads/downloadable_files” sub=”fa-userrole”drawerid=”1″ directories=”off” filenamelabel =”Fichiers partagés” showto “fa-userrole” ]
[stataway type=”table”]
-
First thing’s first:
showto="fa-userrole"just means showto=”everyone” but thefa-userrolephrase doesn’t actually work with theshowtoattribute. So if you only want to show to logged in users, you’ll have to provide a complete comma-separated list of userroles in theshowtoattribute, e.g.,showto="administrator,editor,author,subscriber"Second, do you have stats enabled on your File Away Settings page?
Also,
base="uploads/downloadable_files"is incorrect. The base attribute takes a number from 1 to 5. Sobase="3"for example.Also also,
directories="off"is unnecessary. Just remove thedirectoriesattribute from your shortcode if you don’t want directory tree navigation.Also also also, since you have
sub="fa-userrole", only logged in users will be able to see anything, so you can effectively remove yourshowtoattribute from the shortcode.Thanks you for the fast reply,
i updated my first shortcode
[fileaway type=”table” base=”1″ sub=”fa-userrole”drawerid=”1″ directories=”on” filenamelabel =”Fichiers partagés”]Also also, directories=”off” is unnecessary.
I know it but it’s not working without. By the way i turned it to “on” since i need tree navigation.
Second, do you have stats enabled on your File Away Settings page?
yes I do but when I put the [stataway type=”table”] shortcode we can only see blank table even if I download.
1. Do you have the Ignore Roles/Caps or Ignore Users field set on the Statistics tab of the File Away Settings page? If so, are you excluding yourself from stats?
2. Do you have any javascript errors in your browser console?
1.No, Ignore fields are both blanks.
2. I’ve got few js errors in my console:
(sorry but I don’t know how to send screenshots on this forum)Uncaught Error: Bootstrap requires jQuery
at bootstrap.min.js:7
jquery-ui-timepicker-addon.min.js:5 Uncaught TypeError: Cannot read property ‘timepicker’ of undefined
at jquery-ui-timepicker-addon.min.js:5
at jquery-ui-timepicker-addon.min.js:5
at jquery-ui-timepicker-addon.min.js:5
192.168.222.102/:162 Uncaught TypeError: jQuery(…).footable is not a function
at HTMLDocument.<anonymous> (192.168.222.102/:162)
at j (jquery-1.11.2.min.js:2)
at Object.fireWith [as resolveWith] (jquery-1.11.2.min.js:2)
at Function.ready (jquery-1.11.2.min.js:2)
at HTMLDocument.J (jquery-1.11.2.min.js:2)That’d be why. Something is preventing jQuery from loading on your page. I would look at your other plugins.
I turned off all others plugins, there is still one error:
It seems that jQuery is loading now.Uncaught TypeError: jQuery(…).footable is not a function
at HTMLDocument.<anonymous> (?drawer=downloadable_files:139)
at j (jquery-1.11.2.min.js?ver=1.0.0:2)
at Object.fireWith [as resolveWith] (jquery-1.11.2.min.js?ver=1.0.0:2)
at Function.ready (jquery-1.11.2.min.js?ver=1.0.0:2)
at HTMLDocument.J (jquery-1.11.2.min.js?ver=1.0.0:2)
(anonymous) @ ?drawer=downloadable_files:139
j @ jquery-1.11.2.min.js?ver=1.0.0:2
fireWith @ jquery-1.11.2.min.js?ver=1.0.0:2
ready @ jquery-1.11.2.min.js?ver=1.0.0:2
J @ jquery-1.11.2.min.js?ver=1.0.0:2-
This reply was modified 8 years, 7 months ago by
redwolf49.
Do you have the stataway shortcode on the same page as a fileaway shortcode?
Yes, i do my page look like that:
[fileaway type=”table” base=”1″ sub=”fa-userrole”drawerid=”1″ directories=”on” filenamelabel =”Fichiers partagés” ][stataway type=”table”]
-
This reply was modified 8 years, 7 months ago by
redwolf49.
Then I can’t duplicate your issue. I’d need to take a closer look to help further.
Ok thanks you for the help i will continue to search by myself too.
Hope I will find a solution that’s the last part for my project.Ps: I love your plugin (Small touch of humor are appreciable).
Cool.
The issue is footable.js is not being loaded. Look on your page source and see if you see
file-away/lib/js/footable.jsin there. If so, your remaining javascript error is a mystery to me. If not, you have something somewhere deregistering footable from queue.OR …
try making File Away’s javascript load in the Header All the Time on your Options tab on the File Away Settings page, if you don’t already have it set that way. That should not be the issue, but just try it in case.
file-away/lib/js/footable.js is not here i will look on what can deregister it.
Hey back,
Didn’t find the problem, so i will try by an other way, is is possible to collect data without the stataway table? In the documentation you notice that these data are stocked in a database.
Maybe I can access to this database directly?Hey again,
I just want to notice that my error was coming from my themes which was deregistering footable.js.
Thx for the help -
This reply was modified 8 years, 7 months ago by
The topic ‘Download history’ is closed to new replies.