Jump to content

abmcr

Members
  • Posts

    59
  • Joined

  • Last visited

Profile Information

  • Location
    Aosta Italy

Recent Profile Visitors

4,539 profile views

abmcr's Achievements

Full Member

Full Member (4/6)

11

Reputation

  1. thank you... RockMigrations very useful module...
  2. public static function delete () { $response = [ 'data' => [] ]; $id = wire('input')->get('id'); $page = wire("pages")->get($id)->children(); foreach ($page as $child) { $child->delete(); } $page = wire("pages")->get($id); $page->delete(); $return = true; $response = [ 'esito' => $return, ]; } Via API i want t delete a page and his children ; the code delete only the children because after i get this error "devmessage": { "class": "ProcessWire\\WireException", "code": 0, "message": "Can't delete Page 1345 because it has one or more children.", If i recall the same route (example: https://www.sampleweb.com/api/delete?id=1345) a second time the page parent is correctly deleted But there is a way for call once the route? Thank you
  3. I have setup the module and all work fine: my api send data to a client axios, but i have a problem with a file My api send this data json { "data": [ { "url": "http://p1.test/site/assets/files/1017/gpx.gpx", "title": "prova" } ] } and in the quasar app i need to use the file gpx for show a leaflet map. I get this error Access to fetch at 'http://p1.test/site/assets/files/1017/gpx.gpx' from origin 'http://localhost:8081' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled. in the .htaccess file i have set this lines at the bottom RewriteEngine on Header add Access-Control-Allow-Origin "*" Header add Access-Control-Allow-Headers "origin, x-requested-with, content-type" Header add Access-Control-Allow-Methods "PUT, GET, POST, DELETE, OPTIONS" but the file is not fetched.... What i broken? Thank you (excuse me for the poor english language)
  4. THank you: this work very fine!
  5. I need to manage a simple database: movies and genre (cinema related). I have made two templates (movie and genre). In the movie template a repeater page field manage the relation. All work fine. But i want to get also in the genre backend page the list of related movies, ideally in a new tab. The only way i have found is using the custom markup module, but there is AN alternative way? Thank you in advance
  6. I Think the problem is for the app not approved
  7. Yes: i know this.... but in this case i need to create an admin interface for crud in custom tables... your tutorial may be a good start point for this? Thanks #bernhard!!!
  8. i'm evaluating the feasibility of an application web PW based from a custom php site; actually the site as 10.000 records in a table named articles and about 500.000 record in 4 table related to the articles table . I have two doubts : 1) in the two next year i think the number of articles will increase to 20.000 and 1.000.000 of related records: i think this big data is not a problem, also when there is a complex query. Is correct? 2) most of the related fields are , in PW logic, repeater: there is a right way to import these data in PW database? Thank you
  9. Yes: @Pete after you grab my github, i delete 🙂 For 503 i have no time now for implement 😞
  10. I have refactor a little for using in php 7.2 https://github.com/abmcr/MaintenanceMode Thank you Fatal Error: Uncaught ErrFatal Error: Uncaught Error: Access to undeclared static property: MaintenanceMode::$fM in /home/vl303ic7/envers.vda.it/site/modules/MaintenanceMode/MaintenanceMode.module:94or: Access to undeclared static property: MaintenanceMode::$fM in /home/vl303ic7/envers.vda.it/site/modules/MaintenanceMode/MaintenanceMode.module:94
  11. Php 7.2 : i have an error at line 96 Fatal Error: Uncaught Error: Access to undeclared static property: MaintenanceMode::$fM in /home/vl303ic7/envers.vda.it/site/modules/MaintenanceMode/MaintenanceMode.module:94 self::$fM['type']($f, $fM['label'], $data[$f], $fM['desc']) I am the only? Thank you Fatal Error: Uncaught ErrFatal Error: Uncaught Error: Access to undeclared static property: MaintenanceMode::$fM in /home/vl303ic7/envers.vda.it/site/modules/MaintenanceMode/MaintenanceMode.module:94or: Access to undeclared static property: MaintenanceMode::$fM in /home/vl303ic7/envers.vda.it/site/modules/MaintenanceMode/MaintenanceMode.module:94
×
×
  • Create New...