Gelmiş geçmiş en büyük porno sitemiz olan 2pe de her zaman en kaliteli pornoları sunmayı hedefledik. Diğer video sitemiz olan vuam da ise hd porno ağırlıklı çalışmalara başladık.

  1. #1
    Sencha User
    Join Date
    May 2011
    Posts
    25
    Vote Rating
    0
    invalidoyt is on a distinguished road

      0  

    Default Build with server generated JS

    Build with server generated JS


    Hello all,

    I have a issue with Sencha Cmd.

    In my app, I first load the framework, then I generate settings in JS format on server, and then my app launches with the settings retrieved from the server. See below:

    app.json
    Code:
    
    
    Code:
    {
      "name": "Acente.mobi",
      "indexHtmlPath": "index.html",
      "url": null,
      "js": [
        {
          "path": "touch/sencha-touch.js",
          "x-bootstrap": true
        },
        {
          "path": "http://acente.local:8080/admin/gateway/index.php/settings/setting?mode=app",
          "remote": true
        },
        {
          "path": "app.js",
          "bundle": true,
          "update": "delta"
        },
        {
          "path": "http://maps.google.com/maps/api/js?sensor=true",
          "remote": true
        },
        {
          "path": "resources/source/langs/tur.js"
        },
        {
          "path": "lang.js",
          "update": "delta"
        },
      ],
      "css": [
        {
          "path": "resources/css/app.css",
          "update": "delta"
        }
      ],
      "appCache": {
        "cache": [
          "index.html"
        ],
        "network": [
          "*"
        ],
        "fallback": []
      },
      "resources": [
        "resources/images",
        "resources/icons",
        "resources/startup"
      ],
      "ignore": [
        ".svn$"
      ],
      "archivePath": "archive",
      "id": "a64ea987-ecb3-419b-9510-80134981238f"
    }


    So, when I build this with Testing mode, app.js contains everything including the framework and my app files. And the remote "setting" is added as a <script/> tag into the index.html.

    This breaks my application, because my app files make use of the settings on this remote script. Do you have any idea how to solve this issue? I cant see any way to interfere with the building process.

    Maybe I should find another way in my app.js or in the initial controller to make my settings retrieved from the server usable for the app.

    Any ideas?

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    36,519
    Vote Rating
    813
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    If you list this in app.json, it will attempt to find the file to copy, the remote option does not work in Cmd.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Sencha User
    Join Date
    May 2011
    Posts
    25
    Vote Rating
    0
    invalidoyt is on a distinguished road

      0  

    Default


    But the file retrieved from the server (the setting JS) is not static. It is dynamic and has settings of the application. The client may change the settings at any time on the admin panel.

    If I list it on app.json, I suppose it will get it once and put it statically on the app?

  4. #4
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    36,519
    Vote Rating
    813
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    Cmd doesn't run your application when you build it, it inspects the code. So if you are hitting a server side script like PHP it won't be run. You would need to edit index.html or you could use an index.php as your landing point that is just copied with the build but index.html will get edited by Cmd.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  5. #5
    Sencha User
    Join Date
    May 2011
    Posts
    25
    Vote Rating
    0
    invalidoyt is on a distinguished road

      0  

    Default


    I see. I should change the way I build settings for my app.

    Thank you for replies,

    Have a nice day.

Thread Participants: 1

Tags for this Thread