IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

Conception Web Discussion :

Ressources non trouvées


Sujet :

Conception Web

  1. #1
    Débutant  
    Inscrit en
    Mai 2006
    Messages
    705
    Détails du profil
    Informations forums :
    Inscription : Mai 2006
    Messages : 705
    Points : 117
    Points
    117
    Par défaut Ressources non trouvées
    Bonjour,

    J'essaie de recopier cet exemple (http://alexandre.alapetite.fr/doc-al.../index.fr.html) qui permet de s'interagir avec la webcam; J'ai pas trouvé le projet compressé dans la page donc j'ai crée un dossier sous le dossier www de mon serveur web local, et j'ai copier/coller le code source de la page HTML comme montre le code suivant:

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    130
    131
    132
    133
    134
    135
    136
    137
    138
    139
    140
    141
    142
    143
    144
    145
    146
    147
    148
    149
    150
    151
    152
    153
    154
    155
    156
    157
    158
    159
    160
    161
    162
    163
    164
    165
    166
    167
    168
    169
    170
    171
    <!DOCTYPE html>
    <html itemscope itemtype="http://schema.org/Product">
    <head>
        <meta charset="utf-8"/>
        <base href="/">
        <title>Scan QR Codes with your WebCam</title>
    <meta name="description" lang="en"
          content="Allows to read a QR Code with you WebCam using HTML5 WebRTC API."/>
        <link rel="stylesheet" href="./css/49b12407.generator.css"/>
        <link rel="stylesheet" href="./css/general.css"/>
    
        <link rel="shortcut icon" type="image/x-icon" href="images/icon.png"/>
        <link href='//fonts.googleapis.com/css?family=Roboto:100,100italic,300,300italic,400,400italic,500,500italic,700,700italic,900,900italic'
              rel='stylesheet' type='text/css'>
        <meta property="og:title" content="The QR Code Generator"/>
        <meta property="og:type" content="website"/>
        <meta property="og:url" content="https://www.the-qrcode-generator.com/"/>
        <meta property="og:image"
              content="http://chart.apis.google.com/chart?chs=300x300&amp;cht=qr&amp;chld=|0&amp;chl=http%3A%2F%2Fwww.the-qrcode-generator.com%2F"/>
        <meta property="og:site_name" content="The QR Code Generator"/>
        <meta property="fb:admins" content="100002536485956"/>
    
        <meta itemprop="name" content="QR Code Generator">
        <meta itemprop="description"
              content="Generates QR Codes from URLs, free text, vCards, SMS or Phone Numbers.">
        <meta itemprop="image"
              content="https://www.the-qrcode-generator.com/images/icon.png">
    
        <!--[if lte IE 8]>
        <script type="text/javascript">
            window.location = '/oldie.html';
        </script>
        <![endif]-->
    </head>
    <body data-ng-app="qrApp" role="application">
    
    <div class="container">
            <div data-ng-view="" class="view"><div class="view-scan ng-scope">    <div class="qr-scanner" data-ng-show="isScanning">        <div class="access-hint">            <div class="grant-access">                Please grant access to your webcam...            </div>        </div>        <div data-qr-scanning="" class="qr-continuous-scanner ng-isolate-scope ng-scope" data-on-decoded="onDecoded" data-stopped="!isScanning">        <canvas width="700" height="500"></canvas></div>    </div>    <div data-ng-show="!isScanning" class="qr-scanner-decoded" style="display: none;">        <button class="btn btn-primary" data-ng-hide="isScanning" data-ng-click="isScanning = true" style="display: none;">Scan Again        </button>        <h2>Content of QR Code</h2>        <div class="qr-parsed-content" data-qr-parsed-content="" data-qr-content="decoded">    <div data-ng-switch="" data-on="content.type">        <!-- ngSwitchWhen: sms -->        <!-- ngSwitchWhen: url -->        <!-- ngSwitchWhen: tel -->        <!-- ngSwitchWhen: contact -->        <!-- ngSwitchWhen: text -->        <!-- ngSwitchWhen: geo -->        <!-- ngSwitchDefault:  --><div data-ng-switch-default="" class="default ng-scope">            <div class="type-info">Unknown Type</div>        </div>    </div></div>    </div></div></div>
            
    
            <noscript>
                &lt;div class="static-generator ng-cloak"&gt;
        &lt;div id="help"&gt;&lt;p&gt;
            Please enable JavaScript to generate QR Codes.
            Usage: Enter the information you want to encode as QR Code. A QR
            Code is generated automatically.
        &lt;/div&gt;
        &lt;form id="generate-form" action="/" onsubmit="return false;"&gt;
    
            &lt;div id="tab_bar" class="goog-tab-bar goog-tab-bar-top"&gt;
                &lt;div id="tab_text" class="goog-tab goog-tab-selected"&gt;Free
                    Text
                &lt;/div&gt;
                &lt;div id="tab_url" class="goog-tab"&gt;URL&lt;/div&gt;
                &lt;div id="tab_vcard" class="goog-tab"&gt;Contact&lt;/div&gt;
                &lt;div id="tab_phone" class="goog-tab"&gt;Phone Number&lt;/div&gt;
                &lt;div id="tab_sms" class="goog-tab"&gt;SMS&lt;/div&gt;
            &lt;/div&gt;
    
            &lt;div class="goog-tab-bar-clear"&gt;&lt;/div&gt;
            &lt;div id="tab_bar_content" class="goog-tab-content"&gt;
                &lt;div id="content_text" class="tab-input"&gt;
                    &lt;label for="text"&gt;Free Text:&lt;/label&gt;
                    &lt;textarea id="text" rows="5" cols="30"&gt;&lt;/textarea&gt;
                &lt;/div&gt;
                &lt;div id="content_url" class="tab-input tab-hidden"&gt;
                    &lt;label for="url"&gt;URL:&lt;/label&gt;&lt;input type="text"
                                                        id="url"/&gt;
    
                    &lt;div&gt;
                        &lt;label id="shorten_label"&gt;
                            &lt;input type="checkbox" id="shorten_url"/&gt;
                            Shorten Link
                        &lt;/label&gt;
                    &lt;/div&gt;
    
                &lt;/div&gt;
                &lt;div id="content_phone" class="tab-input tab-hidden"&gt;
                    &lt;label for="phone"&gt;Phone Number:&lt;/label&gt;&lt;input
                        type="text"
                        id="phone"/&gt;
                &lt;/div&gt;
                &lt;div id="content_sms" class="tab-input tab-hidden"&gt;
                    &lt;div&gt;&lt;label for="sms_number"&gt;Phone Number:&lt;/label&gt;
                    &lt;/div&gt;
                    &lt;input type="text" id="sms_number"/&gt;
    
                    &lt;div&gt;&lt;label for="sms_text"&gt;Message:&lt;/label&gt;&lt;/div&gt;
                    &lt;textarea id="sms_text" rows="5" cols="30"&gt;&lt;/textarea&gt;
                &lt;/div&gt;
                &lt;div id="content_vcard" class="tab-input tab-hidden"&gt;
                    &lt;div&gt;&lt;label for="vcard_firstname"&gt;First Name:&lt;/label&gt;
                    &lt;/div&gt;
                    &lt;input type="text" id="vcard_firstname"/&gt;
    
                    &lt;div&gt;&lt;label for="vcard_name"&gt;Name:&lt;/label&gt;&lt;/div&gt;
                    &lt;input type="text" id="vcard_name"/&gt;
    
                    &lt;div&gt;&lt;label for="vcard_org"&gt;Organization:&lt;/label&gt;&lt;/div&gt;
                    &lt;input type="text" id="vcard_org"/&gt;
    
                    &lt;div&gt;&lt;label for="vcard_email"&gt;Email:&lt;/label&gt;&lt;/div&gt;
                    &lt;input type="text" id="vcard_email"/&gt;
    
    
                    &lt;div&gt;&lt;label for="vcard_cell"&gt;Cell Phone Number:&lt;/label&gt;
                    &lt;/div&gt;
                    &lt;input type="text" id="vcard_cell"/&gt;
    
                    &lt;div&gt;&lt;label for="vcard_phone"&gt;Phone Number:&lt;/label&gt;
                    &lt;/div&gt;
                    &lt;input type="text" id="vcard_phone"/&gt;
    
                    &lt;div&gt;&lt;label for="vcard_fax"&gt;Fax Number:&lt;/label&gt;&lt;/div&gt;
                    &lt;input type="text" id="vcard_fax"/&gt;
    
    
                    &lt;div&gt;&lt;label for="vcard_street"&gt;Street:&lt;/label&gt;&lt;/div&gt;
                    &lt;input type="text" id="vcard_street"/&gt;
    
                    &lt;div&gt;&lt;label for="vcard_postcode"&gt;Postcode:&lt;/label&gt;
                    &lt;/div&gt;
                    &lt;input type="text" id="vcard_postcode"/&gt;
    
                    &lt;div&gt;&lt;label for="vcard_city"&gt;City:&lt;/label&gt;&lt;/div&gt;
                    &lt;input type="text" id="vcard_city"/&gt;
    
                    &lt;div&gt;&lt;label for="vcard_region"&gt;Region/State:&lt;/label&gt;
                    &lt;/div&gt;
                    &lt;input type="text" id="vcard_region"/&gt;
    
                    &lt;div&gt;&lt;label for="vcard_country"&gt;Country:&lt;/label&gt;&lt;/div&gt;
                    &lt;input type="text" id="vcard_country"/&gt;
    
                    &lt;div&gt;&lt;label for="vcard_url"&gt;URL:&lt;/label&gt;&lt;/div&gt;
                    &lt;input type="text" id="vcard_url"/&gt;
    
                &lt;/div&gt;
            &lt;/div&gt;
            &lt;div&gt;
                &lt;button id="btn_submit" type="submit"&gt;Generate&lt;/button&gt;
            &lt;/div&gt;
            &lt;div class="clear"&gt;&lt;/div&gt;
    
            &lt;div id="output_tools"&gt;&lt;/div&gt;
        &lt;/form&gt;
        &lt;div id="qrcode_output"&gt;
            &lt;h2&gt;QR Code:&lt;/h2&gt;
    
            &lt;div id="img_container"&gt;
                &lt;img src="http://chart.apis.google.com/chart?chs=200x200&amp;amp;cht=qr&amp;amp;chld=|1&amp;amp;chl=http%3A%2F%2Fwww.the-qrcode-generator.com%2F" alt="qrcode" /&gt;
            &lt;/div&gt;
            &lt;div id="dl_container"&gt;&lt;/div&gt;
        &lt;/div&gt;
    &lt;/div&gt;
            </noscript>
    
                    
                    <div class="social-buttons" data-ng-show="isOnline">           
    
           
        </div>
    
    <script src="./libs/fa5ba54b.libs.js"></script>
    
    
    <script src="./libs/541af4bd.fullapp.js"></script>
    
    </body>
    </html>
    Bien évidemment,j'ai crée deux répertoires libs et css dans les quel j'ai mis les fichiers suivants respectivement (541af4bd.fullapp.js + fa5ba54b.libs.js) et (49b12407.generator.css + general.css).

    Le problème c'est que lorsque j'exécute avec le navigateur, je ne reçois que le message suivant ("please grant access to your webcam...") et lorsque j'inspecte la page, dans le log j'obtiens:

    Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost/css/49b12407.generator.css
    Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost/css/general.css
    Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost/libs/541af4bd.fullapp.js
    Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost/libs/fa5ba54b.libs.js
    Voici l'image qui représente l'hiéarchie de mon projet sous www de mon serveur local

    http://img4.hostingpics.net/pics/441411arch.png

    Merci d'avance!

  2. #2
    Membre éclairé Avatar de Tillo
    Homme Profil pro
    Webmaster
    Inscrit en
    Octobre 2007
    Messages
    494
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Âge : 44
    Localisation : France, Nord (Nord Pas de Calais)

    Informations professionnelles :
    Activité : Webmaster
    Secteur : High Tech - Multimédia et Internet

    Informations forums :
    Inscription : Octobre 2007
    Messages : 494
    Points : 683
    Points
    683
    Par défaut
    Bonjour,

    Si j'ai bien compris, l'adresse de ton projet est localhost/LastQR
    Je pense que le problème vient de cette ligne (la 5e dans ton code) :

    Elle indique au script qu'il faut chercher les dossiers css et libs dans localhost et non dans localhost/LastQR

    A ta place, j'aurais essayé de remplacer

    par

    Pour obliger ton script à "rester" dans le dossier de ton projet.

    Désolé, c'est pas très clair
    Je ne sais pas trop comment expliquer...

    Bon courage
    Alexis
    J'aimerais mieux être le premier dans ce village que le second à Rome. (Caius Julius Caesar)

    J'ai aussi un site sur la Grande Guerre: Histoires de Poilus

Discussions similaires

  1. Ressource non trouvée lors d'une redirection.
    Par a.pellet dans le forum Play!
    Réponses: 6
    Dernier message: 27/05/2010, 17h20
  2. problème ressource non trouvée
    Par likoudA dans le forum Wildfly/JBoss
    Réponses: 0
    Dernier message: 16/05/2010, 22h52
  3. Erreur ressource non trouvée avec WindowBlinds
    Par jbrg dans le forum Langage
    Réponses: 2
    Dernier message: 25/10/2009, 00h09
  4. ressource non trouvé : getSystemResource
    Par Nexussmb dans le forum Langage
    Réponses: 6
    Dernier message: 17/03/2008, 03h46
  5. Image dans ressource non trouvée depuis une dll
    Par WebPac dans le forum API, COM et SDKs
    Réponses: 1
    Dernier message: 17/08/2007, 15h10

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo