Jump to content

fedeb

Members
  • Content Count

    10
  • Joined

  • Last visited

Community Reputation

29 Excellent

About fedeb

  • Rank
    Jr. Member

Profile Information

  • Gender
    Male
  • Location
    Italy

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Thanks for the tip, in fact adding that line fixed the current item class. I misunderstood the use of the keyworkd {class}. Still there is one last problem remaining which I couldn't solve: the <a href=...></a> of the current element does not have the class="page-link" even though the other elements have it. I am trying to solve it myself but cannot manage to do it.
  2. Hi, thanks for the response, already checking the html code outputted in dev tools was helpful: <li class="page-item"> ::marker <a href="/cluster/page10"><span>10</span></a> </li> <li class="page-item"> ::marker <a class="page-link" href="/cluster/page11">11</a> </li> Page 10 (active page) vs Page 11 (non active). The difference is that the class is only "page-item" even though I specified "page-item active" and that <a></a> doesn't have the class page-link. If I add this information manually from the dev too
  3. Hi, I am trying to style the pager navigation bar based on a simple example I found on bootstrap: <nav aria-label="..."> <ul class="pagination"> <li class="page-item disabled"> <a class="page-link" href="#" tabindex="-1" aria-disabled="true">Previous</a> </li> <li class="page-item"><a class="page-link" href="#">1</a></li> <li class="page-item active" aria-current="page"> <a class="page-link" href="#">2</a> </li> <li class="page-item"><a class="page-link" h
  4. Hi, I used matplotlib library from Python. Configuration is the default one so with only few lines you get the plots!
  5. Hi, (almost two years later...😅) I am trying out the latest update of the FieldtypeEvents announced on the latest weekly update by ryan. Since I am new to Fieldtypes (also to ProcessWire) I have some basic questions: 1) When trying to populate the Events field from a php script using $page->save()or $pages->saveField(Page $page, $field) I get the an error raised inside ___sleepValue(): if($event->formatted) throw new WireException('Formatted events cannot be saved'); The error is originated because when loading the information from the database ($value) into an
  6. @ryan for the time being the data (groupID, start, end, sequence) are not supposed to be queryable. Ideally groupID should be, because I would like to display all proteins belonging to a groupID in the group page but I think I will use a workaround for this: I have a file for each group containing this information which I plan to parse when loading the group page. Individual files have at most 1000 lines (proteins). In this way I avoid querying 20+ million entries each time you try to access a particular group page. As you suggested I will load each entry (groupID, start, end, sequence)
  7. Hi, Thanks a lot for all the feedback. I did some additional tests based on all of the suggestions you gave me and results are already amazing!! Figure 1 shows @ryan suggestions tested independently: 1. I created the $template variable outside the loop. 2. I created the $parent variable outside the loop. The boost in performance is surprising! Defining the $parent outside the loop made a huge difference (before I didn't assigned the parent explicitly, it was already defined in the template thus the assignment was automatic) 4. I also tried this suggestion ($page-
  8. Hi, A bit of background. I am creating a website which lets you navigate through a protein database with 20 million proteins grouped into 50 thousand categories. The database is fixed in size, meaning no need to update/add information in the near future. Queries to the database are pretty standard. The problem I am currently having is the time it takes to create the pages for the proteins (right now around a week). Pages are created reading the data from a csv file. Based on previous posts I found on this forum (link1, link2) I decided to use $database transactions to load the d
  9. Hi! I just tried out your solution and it worked perfectly! Thanks a lot for the quick reply and the amazing explanation! Since I am creating temporary files on demand for download I think I don't have a big security issue nor I need to track the files, right? Basically there is a link to a download.php which triggers the download of the file. There is no visible link to that file. I include the download.php code just to close the thread properly. It is probably not the best code so if there something I should change please let me know. // create temp dir $temp_dir =
  10. Hi, I am trying to use wire tempDir (/site/assets/cache/WireTempDir) to store temporary files for users to download. The idea is that the files are created on request, they exist for a few hours till the download is over and then the folder is cleaned automatically. Based on some useful posts I found in the forum I am able to create the files on demand using the following lines: $wire_temp_dir = $files->tempDir('temp_downloads'); $wire_temp_dir->setRemove(false); $temp_path = (string)$wire_temp_dir;; $zip = $temp_path . "test.zip"; $result_zip = $files->zip($zip, $f
×
×
  • Create New...