this the first function that returns the list:
def getListOfKeyWord(keyword):
df=pd.read_excel('finaltrue.xlsx')
corpus=[]
for i in range(len(df)):
if keyword in df["text"][i]:
corpus.append(df["text"][i])
return corpus
this the function where i printing the list as line by line:
def listing(result):
x=0
for item in range(0,len(result)):
x+=1
table = print(x,"",result[item])
return table
this is the placeholder in html :
<div class="row center">
{{key}}
</div>
and here where i call the functions at the app.routing
if request.method=='POST':
word = request.form['kword']
result=getListOfKeyWord(word)
table=listing(result)
return render_template('advance_search.html',key=table)
return render_template('advance_search.html')
now i get a "none" word at the placeholder position can anyone help please ?