質問編集履歴

2

内容追記

2020/07/22 04:14

投稿

fukazume
fukazume

スコア78

test CHANGED
File without changes
test CHANGED
@@ -71,3 +71,195 @@
71
71
  Windows 10
72
72
 
73
73
  Python 3.8.3
74
+
75
+
76
+
77
+
78
+
79
+ ##■CSV出力結果(test.csv)
80
+
81
+ ```csv
82
+
83
+ "<div class=""content"">
84
+
85
+ <div id=""promotions"">
86
+
87
+ </div>
88
+
89
+ <div id=""content_inner"">
90
+
91
+ <article class=""product_page""><!-- Start of product page -->
92
+
93
+ <div class=""row"">
94
+
95
+ <div class=""col-sm-6"">
96
+
97
+ <div class=""carousel"" id=""product_gallery"">
98
+
99
+ <div class=""thumbnail"">
100
+
101
+ <div class=""carousel-inner"">
102
+
103
+ <div class=""item active"">
104
+
105
+ <img alt=""A Light in the Attic"" src=""../../media/cache/fe/72/fe72f0532301ec28892ae79a629a293c.jpg""/>
106
+
107
+ </div>
108
+
109
+ </div>
110
+
111
+ </div>
112
+
113
+ </div>
114
+
115
+ </div>
116
+
117
+ <div class=""col-sm-6 product_main"">
118
+
119
+ <h1>A Light in the Attic</h1>
120
+
121
+ <p class=""price_color"">£51.77</p>
122
+
123
+ <p class=""instock availability"">
124
+
125
+ <i class=""icon-ok""></i>
126
+
127
+
128
+
129
+ In stock (22 available)
130
+
131
+
132
+
133
+ </p>
134
+
135
+ <p class=""star-rating Three"">
136
+
137
+ <i class=""icon-star""></i>
138
+
139
+ <i class=""icon-star""></i>
140
+
141
+ <i class=""icon-star""></i>
142
+
143
+ <i class=""icon-star""></i>
144
+
145
+ <i class=""icon-star""></i>
146
+
147
+ <!-- <small><a href=""/catalogue/a-light-in-the-attic_1000/reviews/"">
148
+
149
+
150
+
151
+
152
+
153
+ 0 customer reviews
154
+
155
+
156
+
157
+ </a></small>
158
+
159
+ --> 
160
+
161
+
162
+
163
+
164
+
165
+ <!--
166
+
167
+ <a id=""write_review"" href=""/catalogue/a-light-in-the-attic_1000/reviews/add/#addreview"" class=""btn btn-success btn-sm"">
168
+
169
+ Write a review
170
+
171
+ </a>
172
+
173
+
174
+
175
+ --></p>
176
+
177
+ <hr/>
178
+
179
+ <div class=""alert alert-warning"" role=""alert""><strong>Warning!</strong> This is a demo website for web scraping purposes. Prices and ratings here were randomly assigned and have no real meaning.</div>
180
+
181
+ </div><!-- /col-sm-6 -->
182
+
183
+ </div><!-- /row -->
184
+
185
+ <div class=""sub-header"" id=""product_description"">
186
+
187
+ <h2>Product Description</h2>
188
+
189
+ </div>
190
+
191
+ <p>It's hard to imagine a world without A Light in the Attic. This now-classic collection of poetry and drawings from Shel Silverstein celebrates its 20th anniversary with this special edition. Silverstein's humorous and creative verse can amuse the dowdiest of readers. Lemon-faced adults and fidgety kids sit still and read these rhythmic words and laugh and smile and love th It's hard to imagine a world without A Light in the Attic. This now-classic collection of poetry and drawings from Shel Silverstein celebrates its 20th anniversary with this special edition. Silverstein's humorous and creative verse can amuse the dowdiest of readers. Lemon-faced adults and fidgety kids sit still and read these rhythmic words and laugh and smile and love that Silverstein. Need proof of his genius? RockabyeRockabye baby, in the treetopDon't you know a treetopIs no safe place to rock?And who put you up there,And your cradle, too?Baby, I think someone down here'sGot it in for you. Shel, you never sounded so good. ...more</p>
192
+
193
+ <div class=""sub-header"">
194
+
195
+ <h2>Product Information</h2>
196
+
197
+ </div>
198
+
199
+ <table class=""table table-striped"">
200
+
201
+ <tr>
202
+
203
+ <th>UPC</th><td>a897fe39b1053632</td>
204
+
205
+ </tr>
206
+
207
+ <tr>
208
+
209
+ <th>Product Type</th><td>Books</td>
210
+
211
+ </tr>
212
+
213
+ <tr>
214
+
215
+ <th>Price (excl. tax)</th><td>£51.77</td>
216
+
217
+ </tr>
218
+
219
+ <tr>
220
+
221
+ <th>Price (incl. tax)</th><td>£51.77</td>
222
+
223
+ </tr>
224
+
225
+ <tr>
226
+
227
+ <th>Tax</th><td>£0.00</td>
228
+
229
+ </tr>
230
+
231
+ <tr>
232
+
233
+ <th>Availability</th>
234
+
235
+ <td>In stock (22 available)</td>
236
+
237
+ </tr>
238
+
239
+ <tr>
240
+
241
+ <th>Number of reviews</th>
242
+
243
+ <td>0</td>
244
+
245
+ </tr>
246
+
247
+ </table>
248
+
249
+ <section>
250
+
251
+ <div class=""sub-header"" id=""reviews"">
252
+
253
+ </div>
254
+
255
+ </section>
256
+
257
+ </article><!-- End of product page -->
258
+
259
+ </div>
260
+
261
+ </div>"
262
+
263
+
264
+
265
+ ```

1

誤字訂正

2020/07/22 04:14

投稿

fukazume
fukazume

スコア78

test CHANGED
File without changes
test CHANGED
@@ -14,7 +14,7 @@
14
14
 
15
15
 
16
16
 
17
- しかし、記コードを実行しても、CSVとしてレコードのフィールド内にうまく収まってくれません。
17
+ しかし、記コードを実行しても、CSVとしてレコードのフィールド内にうまく収まってくれません。
18
18
 
19
19
 
20
20
 
@@ -61,3 +61,13 @@
61
61
  ##■質問
62
62
 
63
63
  上記目的を達成するための常套の手法などございましたらヒントなどいただけますと誠にありがたく存じます。
64
+
65
+
66
+
67
+
68
+
69
+ ##■環境
70
+
71
+ Windows 10
72
+
73
+ Python 3.8.3