Les avertissements suivants se sont produits :
Warning [2] Undefined array key 0 - Line: 1640 - File: showthread.php PHP 8.2.18 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/showthread.php 1640 errorHandler->error_callback
/showthread.php 915 buildtree




Note de ce sujet :
  • Moyenne : 0 (0 vote(s))
  • 1
  • 2
  • 3
  • 4
  • 5
Module et routage d'url, comment ça marche ?
#1
Citation :#~~~~~ DEBUT BLOC A NE PAS SUPPRIMER ~~~~~
#~ Version du CMS: !1.11.9
#~ Url du site :
#~ Hébergeur / Soft : Ubuntu server + apache2 + mysql + php5...
#~ Informations Système :
#~ ----------------------------------------------
#~ Cms Version: 1.11.9
#~ Installed Modules:
#~ CMSMailer: 5.2.2
#~ CMSPrinting: 1.0.5
#~ FileManager: 1.4.3
#~ MenuManager: 1.8.6
#~ MicroTiny: 1.2.5
#~ ModuleManager: 1.5.5
#~ News: 2.14.1
#~ Search: 1.7.11
#~ ThemeManager: 1.1.8
#~ MultiDomains: 2.1.1
#~ CGSimpleSmarty: 1.7.1
#~ CGExtensions: 1.38.1
#~ MleCMS: 1.11.4
#~ CGGoogleMaps: 2.4.5
#~ HostedVideoAlbums: 2.4.3
#~ AdvancedContent: 0.9.4.3
#~ FormBuilder: 0.7.4
#~ Captcha: 0.4.6
#~ Gallery: 1.6.1
#~ JQueryTools: 1.2.5
#~ CGContentUtils: 1.3.4
#~ Products: 2.19.5.1
#~ MysqlDump: 1.3.1
#~ AceEditor: 0.2.5
#~ CGSmartImage: 1.15
#~ CompanyDirectory: 1.20
#~ Postcode: 1.2.1
#~ FrontEndUsers: 1.21.18
#~ CustomContent: 1.9
#~ Uploads: 1.14.4
#~ TemplateExternalizer: 2.1.3
#~ SelfRegistration: 1.8
#~ CGEcommerceBase: 1.4.2
#~ MultiPrice: 1.1.0
#~ CGUserDirectory: 1.4.1
#~ OBfeumanager: 0.0.1
#~ GAMadeSimple: 1.1
#~ OBSelfregValidator: 0.0.1
#~ Config Information:
#~ php_memory_limit:
#~ process_whole_template:
#~ max_upload_size: 50000000
#~ url_rewriting: mod_rewrite
#~ page_extension: /
#~ query_var: page
#~ image_manipulation_prog: GD
#~ auto_alias_content: true
#~ locale:
#~ default_encoding: utf-8
#~ admin_encoding: utf-8
#~ set_names: true
#~ Php Information:
#~ phpversion: 5.5.9-1ubuntu4
#~ md5_function: On (True)
#~ gd_version: 2
#~ tempnam_function: On (True)
#~ magic_quotes_runtime: Off (False)
#~ E_STRICT: 2048
#~ E_DEPRECATED: 8192
#~ memory_limit: 128M
#~ max_execution_time: 60
#~ output_buffering: 4096
#~ safe_mode: Off (False)
#~ file_uploads: On (True)
#~ post_max_size: 50M
#~ upload_max_filesize: 50M
#~ session_save_path: /var/lib/php5 (1733)
#~ session_use_cookies: On (True)
#~ xml_function: On (True)
#~ xmlreader_class: On (True)
#~ Server Information:
#~ Server Api: apache2handler
#~ Server Db Type: MySQL (mysqli)
#~ Server Db Version: 5.5.37
#~ Server Db Grants: Found a "GRANT ALL" statement that appears to be suitable
#~ Server Time Diff: No filesystem time difference found
#~ ----------------------------------------------
#~~~~~ FIN BLOC A NE PAS SUPPRIMER ~~~~~



Voilà, j'essaie de créer un module qui doit être joignable via une url spécifique (fournie via mail).
En gros, cette url, lorsqu'elle est appelée devrait charger une action spécifique de mon module (récupérer un paramètre et afficher un formulaire)

J'ai consulté le cookbook cmsms et retourné certains modules. Je dois ajouter ceci dans la fonction SetParameters de mon module:

Code :
[== PHP ==]
    $contentops = cmsms()->GetContentOperations();
    $returnid = $contentops->GetDefaultContent();
    $parms = array('action'=>'default','returnid'=>$returnid);
    $route = new CmsRoute('invite/', $this->GetName(),$parms,TRUE);

    cms_route_manager::register($route);

J'ai ensuite créé un fichier action.default.php pour voir si il y avait une réaction. (un simple echo suivit d'un exit)

Cela ne marche pas.

Comment faire ???
Répondre


Messages dans ce sujet

Atteindre :


Utilisateur(s) parcourant ce sujet : 1 visiteur(s)