-
Posts
4,080 -
Joined
-
Last visited
-
Days Won
87
Everything posted by horst
-
have had some hours last evening (exactly 8 'til now) I think I can finish the import next time I get 2-3 hours. So, don't know when now. There is some trouble with chars in filenames and ID3-Tags that want not get into the DB, so I have played around with sanitizer, but have to go deeper and change the current behave. Here are a screencast of the backend, starting with an empty DB (no mp3 data in it) set one or more pathes, do a quick filesystem scan (without parsing ID3 etc) envoke a command line script to perform scan with parsing mp3 files and pull data into DB: (please look fullscreen or otherwise enlarge Video) https://youtu.be/Re08fuNFRao
-
Hi Soma, I'm actually working on scanning filesystem and parse 5000 files for metadata. As I run into errors (e.g. not knowing to use $sanitizer->selectorValue()) I don't want to wait 3 minutes every loop, - so store a serialized array in cache-file (site/assets/cache/). I've asked to get a sense for the possibilities. Actually I only will use the ModuleConfigData-storage for some Path- and Extension-strings. Thanks, it only implements ConfigurableModule, so it must have Module allready. (will look into that closer) EDIT: have found this Post: http://processwire.com/talk/topic/1313-modules-process-and-the-difference/#entry11738
- 9 replies
-
- module
- ConfigurableModule
-
(and 1 more)
Tagged with:
-
Can I also use it with extending Process instead of WireData? class MyModule extends Process implements Module, ConfigurableModule { That's awesome! I will change that after finishing some other parts Is there a limit on size to store? For example can I store a serialized array of 5MB or are any bads with that ? Many thanks!
- 9 replies
-
- module
- ConfigurableModule
-
(and 1 more)
Tagged with:
-
Ryan, that's great! It's that kind of great things one will find lots when starting to work with PW. In the past there were so much things that couldn't achvied or only with clumpsy workarounds. I just have to learn to think more positive and first try to find the most simplest solution, than look into PW to realise that it is almost in, or sometimes to get surprised that there even is a more comfortable and easier solution than that I could imagine.
-
Thanks Luis. - so have to say: I only want put together the basic stuff but also want to keep it modular and scalable. For example I personally only use mp3-files but if people use other formats like ogg they should be able to extend the class module for that easily. Maybe with some help it could become really nice and not only poor basic ;-) If someone has good skills on how to build / design / layout admin pages with that UI-stuff it would be really helpful if he/she could design the output for the backend. Also if someone is good with frontend design and want to collaborate that would be great too. I have a really short screencast of what I have done till now, (most of this was learning how to send green or red messages to admin screen, how / where to store config data, to create permissions and roles, and basically how to create a module that has a page in the admin section, ...): https://youtu.be/u_S8ajLkzRI Next steps are to parse ID3Tags, compare file-data with DB-data and import new tracks. Question: is it possible to store arrays or WireData on a page?
-
Hi Soma, that's perfect for this needs, as I allready create a page for the module, I now also create a childpage for the config data. I have to learn to think less complicated when working with PW! I also have created 2 permissions and 2 roles to have access control. It tooks only 5 minutes for this! (Das ist so geil!) If I have not allready said it: I love ProcessWire!
- 9 replies
-
- 1
-
-
- module
- ConfigurableModule
-
(and 1 more)
Tagged with:
-
Hi, I create a little module that extends Process and creates a page in backend under setup. I need to store and retrieve a few (config)data for it, but don't want to make it a ConfigurableModule because than I have redundant places where I can setup config-data , I guess. How can I store / retrieve some data into the place where modules store it by default, but without implementing ConfigurableModule?
- 9 replies
-
- module
- ConfigurableModule
-
(and 1 more)
Tagged with:
-
Ooh, - now I've got it right: the problem are not the ImagePathes in Textareas but _all_ pathes because you setup different sites like http://localhost/mysite1/ , http://localhost/mysite2/ , ... --- You may use Apache with vHosts and generic names like: http://pw1.machine.local/ , http://pw2.machine.local/ , http://pw3.machine.local/ , ... --- Maybe one could use basic httpd.conf (without http-vhosts.conf) and edit two lines in it: #DocumentRoot "C:/Apache2/htdocs" DocumentRoot "C:/WEBSITES/pw1/htdocs" #DocumentRoot "C:/WEBSITES/pw2/htdocs" and #<Directory "C:/Apache2/htdocs"> <Directory "C:/WEBSITES/pw1/htdocs"> #<Directory "C:/WEBSITES/pw2/htdocs"> to match the systempath of the site you are actually working on? --- or you may have one Docroot and Directory in httpd.conf pointing to for example "C:/Apache2/website/htdocs" and in filesystem you have folders for your sites like C:/Apache2/website.PW1/htdocs C:/Apache2/website.PW2/htdocs C:/Apache2/website.PW3/htdocs and you alter the path to C:/Apache2/website/htdocs for the site you work on. This only needs one edit and Apache restart isn't necessary. --- I go with the vhosts
-
Great!
-
Hey Macrura, really nice that you want to help out! - But, with this id3 reading and writing stuff I'm allready perfectly equipped. - What would be good to have is functional mp3-streaming code. Playlistgeneration and ServersidePlaying (for win) is already in tha house, too.
-
Ah, I did know it: it was totally silly! --- I'm not sure, and I've forgotten the Genre-Field, but I think mostly I want to search for an Artist or an Album or a Genre, - or, what would be really nice: want to have 50 or any number random Tracks of specified Genre or Artist as playlist output.
-
Hi Wanze, many thanks for your suggestions! With the first one I'm not sure how to solve that. The second one would just reflect the filesystem. Not bad, because it's like i use it since ever --- But (maybe it's totally silly): could it be an option to have only one Template (Tracks) with the fields: Artist, Album, Trackname Tracknumber, and some other (tracklength, ...) and one record per mp3file? Or will this slow down PW by searching / sorting? (15 - 20.000 files) (I came up with this when thinking about how to solve your first suggestion)
-
sure!
-
Sorry, have no more ideas. It's up to the pro's here.
-
Hhm, that's a thing for the pro's. Only thing what comes to my mind is if you use an AdminTheme in your sites-folder you can do one test with it disabled (renamed) to see if the missing elements get suppressed by it. ??
-
Hi, I'm thinking on using PW to scan my MP3-folders and want ask how you would organize the data. I want to store 'Trackname', 'Artistname', and 'Albumname' & 'Tracknumber', if Track belongs to an Album. (most will do, but not all). I want to be able to do fast (Selector) searches and sortings on combinations of this fields. Any suggestions for a PW-newbie?
-
replace the complete wire folder with the new one, but keep the sites-folder unchanged (just delete / copy or rename to backup and copy new)
-
Hi owzim, I'm a bit curious, but you have set up local and online-dev host yourself? If yes, you shouldn't setup them that different when using absolute image-pathes in textareas But to be serious again, - and besides the good solutions from the others on how to adjust it, - you may take a look to somas Images Manager for future projects:
-
I'm not sure, but could be that you have the last stable PW and this feature you looking for is only in last dev-branch: https://github.com/ryancramerdesign/ProcessWire/tree/dev EDIT: Ok, apeisa is to fast for me
-
Yes, that's what I've meant with "... if the CSS works 100%". But I think this is not that bad for old browser support ;-)
-
with IE8 I get 1 JS-Error related to themeforest (unknown var 'marketplace') The Site runs very well (also in a XP-virtualbox). I'm not sure if the CSS works perfectly but nearly 95% it should be.
-
Hi Wanze, yes with the FPDI extension you can import other PDFs, but in different ways. What I mean with 'as Background' and what I'm find very useful is, for example: You can take a PDF with your e.g. Briefkopf , assuming you have a first page with all your stuff (Logo, adress, bankinfo, tax number, etc.) and a second page with less data (maybe a smaller version of your Logo and only name and phone number), and use it as background-layers: // example use of FPDI-Extension with FPDF. $tplfile = 'C:/fpdf/templates/mein_briefkopf.pdf'; $pagecount = $this->pdf->setSourceFile($tplfile); // defining the sourcefile returns Pagenumber of it for($i=1;$i<=$pagecount;$i++) { $this->fpdiTemplates['tpl_s'.$i] = $this->pdf->ImportPage($i); // import each page and assign it to a variable } $this->Parser_Opened = TRUE; $this->Use_Template = $this->fpdiTemplates['tpl_s1']; ... // write own stuff to the first page // switch the Template to the second page for all // following pages (optional) $this->Use_Template = $this->fpdiTemplates['tpl_s2']; ... // create more pages With the use of FPDI-Templates you can add graphical stuff to your pdf-pages with less effort. On my website one can add images to a virtual lightbox and can download them as a PDF. There are three template pages: one for the image pages, one with my contact-data and copyright notice! and optional one for user notes. ..., und viele Grüße in die Schweiz
-
Sorry for be a bit OT, but I was wondering when viewing the Forum with IE10 it doesn't realize Linebreaks within the code. Is this only on my machine or have others experienced this too? (I normally don't use IE)
-
Hi Wanze, great work and very useful! I have one question: do you plan to embedd the FPDI-Extension into it? I know it from working with FPDF. In the past FPDI-Extension couldn't bundled with TCPDF a long time because of the licence, but this has changed a few year ago. Would be useful to upload or otherwise specify a PDF as background on a 'per-Template-Basis'. (<= uh, ugly Denglish)
-
Hi WillyC, I try to answer in your language: once.need feature.this i will.do u said much.will learn. ready i then .great