Comments (37)
Hello, yes, the command line sqlite3 is installed, but the PHP module with the same name is probably not, as it's not listed in your "PHP extensions", neither is "pdo_sqlite". You need to enable the PHP module.
This one --> https://www.php.net/manual/en/class.sqlite3.php
from kirby3-simplestats.
You're welcome, I'm happy it works now. :)
from kirby3-simplestats.
Hello, your plugin should be up & running.
- Any issues should be reported to
site/logs/simplestats_errors.txt
. - The panel is for viewing the collected stats only. After 24h there should be something visible. You can also view the raw database file with an SQL viewer (
site/logs/simplestats.sqlite
). - You can customise your setup up in
site/config/config.php
like any other kirby plugin. (available options to override are listed inoptions.php
)
from kirby3-simplestats.
Hi Daandelange, thanks for the quick support! It’s still a bit fuzzy for me, but I’ll wait 24h and see if something’s pops up.
Right now, I only have the plugin on my local installation (laravel valet). Is this a problem?
And in my panel, it is unclear where I should go to see the stats 🤔
from kirby3-simplestats.
It should be in your site's main menu. If not, there might be something wrong...
from kirby3-simplestats.
Oh! This is so easy! 🤦♂️
I have a new error message now 😬
from kirby3-simplestats.
And on my remote install, this is the error message Class 'SQLite3' not found
. 😔
from kirby3-simplestats.
For the Database issue, I'll try to reproduce it. Do your dev tools' network monitor reveal something more useful ? Is there something in simplestats_errors.txt
?
The 2nd one speaks for itself, you don't have SQLite3 enabled on your server. (worth looking if you can enable it trough php.ini
or your hoster's admin panel)
from kirby3-simplestats.
There were some files missing for being plug-and play. Can you test with the latest version ?
from kirby3-simplestats.
Hey Daandelange, I reinstalled with your new version.
Will look into activating 'QLite3 on the remote one.
Same error message on the local. Dev console says [Error] Failed to load resource: the server responded with a status of 500 (Internal Server Error) (pagestats, line 0)
from kirby3-simplestats.
I've tested the plugin on a fresh install, the latest version works on my side, but that's only 1 possible configuration.
If you're familiar with php code, you can enable Kirby debugging and trace back errors that don't appear in site/logs/simplestats_errors.txt
.
Edit: #7 says you might have to create the site/logs
folder so the database file can be created.
from kirby3-simplestats.
Hey there, I tried on a fresh install as well. Same error Unable to open database: unable to open database file
.
And on both install, even with Kirby debugging, the logs folder is missing.
If it might help, I’m running my local version through the latest version of Valet. Don’t know if it’s relevant.
from kirby3-simplestats.
Did you try creating the logs folder ? (after which the db and log file should appear on visiting your website ?)
If not, the plugin is probably not able to load itself correctly in Kirby, maybe it's something to do with Valet.
from kirby3-simplestats.
Bingo, got it. Now works on my local installation :)
There’s no stats, but I guess this is because it’s local, duh.
Got some error thought. I’ll let you know how it goes on my remote install as soon as I got SQLite on it.
simplestats_errors.txt
from kirby3-simplestats.
Hum, on dubious. On the remote, my hosting companies informed me SQlite 3 is in place, and the Terminal agrees.
from kirby3-simplestats.
The error in your logfile has just been fixed. (update simplestats)
As for SQLite3... that screenshot looks like the unix command line binary, what you need is the PHP Module.
You could try removing the \
here.
Otherwise, as a temporary solution, upload the locally generated database to your online server, to bypass the SQLite3 requirement.
from kirby3-simplestats.
With the new version and the upload of the simplestats.sqlite
file, I have a new error! could not find driver
from kirby3-simplestats.
That seems to be related to Kirby's PDO/SQLITE driver used by this plugin.
Maybe this thread can give you some directions. (look at phpinfo()
if the PHP PDO SQLite3 module is enabled, and try to install that composer dependency)
from kirby3-simplestats.
I’ll need a bit more help to go through these steps; it is quite confusing for me.
- Add "ext-pdo_sqlite": "*" to my composer.json in the require block
We’re talking about the composer.json file located on the kirby
folder, right?
- Run composer update to update the composer.lock file
I don’t know how to do that
- Deploy
It’s already deployed if it’s on my remote (FTP) server, right?
from kirby3-simplestats.
- No, the one in the plugin folder.
When you then run the composer update, it will update the plugin filles and make the necessary changes to integrate that extra dependency.
So you might need to re-upload the plugin files after that. Refer to the Kirby Composer Guide for more detailed instructions.
from kirby3-simplestats.
Got it, thanks for the steps. Same error on my remote install :/
from kirby3-simplestats.
I've just updated the plugin, including a draft of a requirements checker in the Information tab (panel).
Could you check if all requirements are there ? Hopefully that gives a better insight.
from kirby3-simplestats.
Works great on the local instal. On the remote one, it shows nothing :(
from kirby3-simplestats.
Does it show anything useful on website.domain/api/simplestats/listdbinfo?csrf=YOURTOKEN
? (you need to set the CSRF in your config.php : 'api.csrf' => 'YOURTOKEN',
)
from kirby3-simplestats.
{"status":"error","message":"could not find driver","code":500,"key":null,"details":[]}
from kirby3-simplestats.
Hmm, ok, probably the Kirby\Database\Database
class that doesn't work in your configuration.
I've made the requirements check "autonomous", so it should work now. Please check the message in the panel again, or website.domain/api/simplestats/checkrequirements?csrf=YOURTOKEN
.
from kirby3-simplestats.
New error. the pop out when I open the page in the panel says
Return value of daandelange\SimpleStats\SimpleStatsDb::database() must be an instance of Kirby\Database\Database, null returned
Database Requirements says
PHP Extensions=Core, date, libxml, openssl, pcre, zlib, filter, hash, pcntl, readline, Reflection, SPL, session, standard, cgi-fcgi, bcmath, bz2, calendar, ctype, curl, dba, dom, mbstring, ftp, gd, gettext, iconv, imap, intl, json, ldap, exif, mysqlnd, odbc, PDO, pgsql, Phar, posix, shmop, SimpleXML, soap, sockets, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, xml, xmlwriter, xsl, zip, mysqli, pdo_mysql, PDO_ODBC, pdo_pgsql, xmlreader, xmlrpc --- PHP=OK --- SQLite3=ERROR --- SQLite3.try=ERROR Class 'SQLite3' not found --- CreateDB()=ERROR:could not find driver --- pdo_sqlite=ERROR --- sqlite3=ERROR
And the url https://www.jolinmasson.com/api/simplestats/checkrequirements?csrf=COUCOU
says
{"dbRequirements":"PHP Extensions=Core, date, libxml, openssl, pcre, zlib, filter, hash, pcntl, readline, Reflection, SPL, session, standard, cgi-fcgi, bcmath, bz2, calendar, ctype, curl, dba, dom, mbstring, ftp, gd, gettext, iconv, imap, intl, json, ldap, exif, mysqlnd, odbc, PDO, pgsql, Phar, posix, shmop, SimpleXML, soap, sockets, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, xml, xmlwriter, xsl, zip, mysqli, pdo_mysql, PDO_ODBC, pdo_pgsql, xmlreader, xmlrpc --- PHP=OK --- SQLite3=ERROR --- SQLite3.try=ERROR Class 'SQLite3' not found --- CreateDB()=ERROR:could not find driver --- pdo_sqlite=ERROR --- sqlite3=ERROR"}
from kirby3-simplestats.
Ok, thanks, so that clarifies a lot. They say the same thing : Your php extensions sqlite3
(for SQLite3) and pdo_sqlite
(used by Kirby\Database\Database
) are not available. And they are at the core of this plugin. IMO, the easiest solution would be porting SimpleStats to optionally use MySQL databases (which seem to be enabled on your host) instead of SQLite3; but that is out of my scope... but I can give some directions for such changes if you wish.
Of course, a very simple solution would be to ask your hoster to enable them, or enable them yourself if you have access to custom php.ini
or via your hoster's site admin panel. Or change your hoster.
from kirby3-simplestats.
My host replied me that! Does it help?
While checking through your concern, The sqlite3 is installed manually on the server.
Please check the same from your end,
++++++++++++++
root@golf [~]# sqlite3
SQLite version 3.6.20
Enter ".help" for instructions
Enter SQL statements terminated with a ";"
sqlite>
from kirby3-simplestats.
I indeed ran the command in ter Remote terminal, and it does seams to be installed.
My domain is a secondary domain on my host. Could that be what causes the problem?
from kirby3-simplestats.
They say it’s already installed 😑.
from kirby3-simplestats.
Well, then something weird is happening on your host, it's not enabled on your Kirby installation.
In the panel's simplestats requirement check, the extensions that your Kirby php installation can use are listed after PHP Extensions=**your**extensions**
, so then you might need to compare the output of php -m
and the list in the panel. If they differ, your server setup is using a different PHP environment then the one in the console. Try creating an info.php
(with <?php phpinfo(INFO_MODULES); ?>
) file in your Kirby root and compare the extensions listed there.
from kirby3-simplestats.
Here’s my info.php
I tried to 'activate' sqlite by adding these three lines at the end of my php.ini, but it made my site crash (I have not a lot of clue about what I’m doing actually 😑).
extension=curl
extension=pdo_sqlite
extension=sqlite3
The output of the console and the site don’t match :/
SimpleStats output.txt
Terminal server.txt
from kirby3-simplestats.
Yes, that's the regular way to go. A crash means it doesn't accept your new lines it's very strict. Sometimes you need to add .so
(or .dll
on WIN). Try them one by one until it works, search online, or ask your hoster for support on how to enable it, read their FAQ.
from kirby3-simplestats.
Ooooof, I asked to activate the extension… so they switched my PHP to 5.6, breaking my site in the process. 😑 I asked a second time, and they reverted to 7.3 and activated the extension. It now works like a charm!
Geez, that was not so complicated, and entirely on their end. Thanks a lot Daandelange for the support during all this process!
from kirby3-simplestats.
Hey Maandenlange, I think I’m cursed. I did a clean install of the plugin + database last weekend, now that I have the requirements.
I used a VPN to visit my website, see if it worked, and 48 hours, I still have no stats 😭.
Any clue?
from kirby3-simplestats.
Hey Jolin, I guess that you're not connected to the panel using your VPN ?
Is the logfile empty ? Did you try deleting the db file and let it create a new one ? (looks like it's already the case, but you never know...)
Don't bother waiting 24/48H : If there's nothing in this view ( cf: No rows available
), nothing will appear later.
Did you try if referrer tracking works (instantly appears) ?
Any other clue... try disabling the Kirby cache or other settings that could affect tracking ? (Try a clean plainkit/starterkit on your configuration?)
from kirby3-simplestats.
Related Issues (20)
- authorizedRoles not working properly HOT 2
- Feature request: Export function HOT 4
- Feature request: ignore localhost HOT 4
- Feature request: customise breadcrumb label HOT 1
- UI Conflict with Pagetable plugin HOT 3
- Feature request: option to exclude bots HOT 9
- Clarify TimeFrame switching and notify on user mistakes HOT 5
- Software Tests HOT 1
- [Documentation] Composer installation according to docs fails HOT 1
- GDPR notice in README HOT 7
- Use page unique IDs HOT 4
- Roles and permission related features
- Previous chart color and style easier to read? HOT 5
- Empty SimpleStats page HOT 8
- How to "enable" tracking^^ HOT 16
- Bug when login as unknown user role HOT 1
- Page section blueprint : broken and js error thrown HOT 18
- [K4] Missing Panel Tabs in SimpleStats Plugin HOT 3
- [K4] Kirby 4 issues list
- Broken timeline HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from kirby3-simplestats.